Updated styles for action bar and tab view
This commit is contained in:
parent
aa57494bb7
commit
98dd32f9b8
25 changed files with 199 additions and 202 deletions
101
OsmAnd/res/layout/download.xml
Normal file
101
OsmAnd/res/layout/download.xml
Normal file
|
@ -0,0 +1,101 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:orientation="vertical"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_marginTop="?attr/actionBarSize">
|
||||
|
||||
<net.osmand.plus.views.controls.PagerSlidingTabStrip
|
||||
android:id="@+id/sliding_tabs"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="?attr/actionBarSize"
|
||||
android:background="?attr/colorPrimary"/>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ProgressView"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:visibility="gone">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="3dp"
|
||||
android:layout_marginRight="5dp"
|
||||
android:gravity="center_vertical|left"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/IndeterminateProgressBar"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentTop="true"
|
||||
android:indeterminate="true"
|
||||
android:indeterminateOnly="true"
|
||||
android:visibility="gone"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/ProgressPercent"
|
||||
android:layout_width="48dp"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerVertical="true"
|
||||
android:gravity="right|center_vertical"
|
||||
android:text=""
|
||||
android:textSize="14sp"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/ProgressMessage"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginLeft="3dp"
|
||||
android:layout_toLeftOf="@id/ProgressPercent"
|
||||
android:layout_toRightOf="@id/IndeterminateProgressBar"
|
||||
android:ellipsize="end"
|
||||
android:gravity="left|center_vertical"
|
||||
android:singleLine="true"
|
||||
android:text=""
|
||||
android:textSize="14sp"/>
|
||||
</RelativeLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="5dp"
|
||||
android:layout_marginRight="5dp"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/DeterminateProgressBar"
|
||||
style="?android:attr/progressBarStyleHorizontal"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/Cancel"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/a_1_navigation_cancel_small_dark"/>
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<android.support.v4.view.ViewPager
|
||||
android:id="@+id/pager"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"/>
|
||||
|
||||
<Button
|
||||
android:id="@+id/DownloadButton"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="@string/download_files"
|
||||
android:visibility="gone"/>
|
||||
|
||||
</LinearLayout>
|
|
@ -1,25 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:layout_marginTop="?attr/actionBarSize">
|
||||
|
||||
<net.osmand.plus.views.controls.PagerSlidingTabStrip
|
||||
android:id="@+id/sliding_tabs"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="?attr/actionBarSize"
|
||||
android:background="?attr/colorPrimary"/>
|
||||
|
||||
<android.support.v4.view.ViewPager
|
||||
android:id="@+id/pager"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<net.osmand.plus.activities.search.toolbar.SplitToolbar
|
||||
android:id="@+id/bottomControls"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content" />
|
||||
|
||||
</LinearLayout>
|
|
@ -37,6 +37,7 @@
|
|||
|
||||
<net.osmand.plus.activities.search.toolbar.SplitToolbar
|
||||
android:orientation="horizontal"
|
||||
android:background="?attr/bottomToolBarColor"
|
||||
android:id="@+id/bottomControls"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"/>
|
||||
|
|
|
@ -1,116 +1,26 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<TabHost xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@android:id/tabhost"
|
||||
android:paddingTop="?attr/actionBarSize"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:layout_marginTop="?attr/actionBarSize">
|
||||
|
||||
<LinearLayout
|
||||
android:orientation="vertical"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
<net.osmand.plus.views.controls.PagerSlidingTabStrip
|
||||
android:id="@+id/sliding_tabs"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="?attr/actionBarSize"
|
||||
android:background="?attr/colorPrimary"/>
|
||||
|
||||
<net.osmand.plus.views.controls.PagerSlidingTabStrip
|
||||
android:id="@+id/sliding_tabs"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="?attr/actionBarSize"
|
||||
android:background="?attr/colorPrimary"/>
|
||||
<android.support.v4.view.ViewPager
|
||||
android:id="@+id/pager"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"/>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ProgressView"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:visibility="gone">
|
||||
<net.osmand.plus.activities.search.toolbar.SplitToolbar
|
||||
android:id="@+id/bottomControls"
|
||||
android:background="?attr/bottomToolBarColor"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"/>
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="3dp"
|
||||
android:layout_marginRight="5dp"
|
||||
android:gravity="center_vertical|left"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/IndeterminateProgressBar"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentTop="true"
|
||||
android:indeterminate="true"
|
||||
android:indeterminateOnly="true"
|
||||
android:visibility="gone" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/ProgressPercent"
|
||||
android:layout_width="48dp"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerVertical="true"
|
||||
android:gravity="right|center_vertical"
|
||||
android:text=""
|
||||
android:textSize="14sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/ProgressMessage"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginLeft="3dp"
|
||||
android:layout_toLeftOf="@id/ProgressPercent"
|
||||
android:layout_toRightOf="@id/IndeterminateProgressBar"
|
||||
android:ellipsize="end"
|
||||
android:gravity="left|center_vertical"
|
||||
android:singleLine="true"
|
||||
android:text=""
|
||||
android:textSize="14sp" />
|
||||
</RelativeLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="5dp"
|
||||
android:layout_marginRight="5dp"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/DeterminateProgressBar"
|
||||
style="?android:attr/progressBarStyleHorizontal"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/Cancel"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/a_1_navigation_cancel_small_dark" />
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<net.osmand.plus.CustomPager
|
||||
android:id="@+id/pager"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/DownloadButton"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="bottom"
|
||||
android:layout_marginLeft="3dp"
|
||||
android:layout_marginRight="3dp"
|
||||
android:layout_marginTop="3dp"
|
||||
android:gravity="center"
|
||||
android:text="@string/download_files"
|
||||
android:visibility="gone" />
|
||||
|
||||
<net.osmand.plus.activities.search.toolbar.SplitToolbar
|
||||
android:id="@+id/bottomControls"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content" />
|
||||
</LinearLayout>
|
||||
|
||||
</TabHost>
|
||||
</LinearLayout>
|
|
@ -6,6 +6,7 @@
|
|||
<declare-styleable name="OsmAndTheme">
|
||||
<attr name="expandable_category_color" format="reference"/>
|
||||
<attr name="reset_image" format="reference"/>
|
||||
<attr name="bottomToolBarColor" format="color" />
|
||||
</declare-styleable>
|
||||
|
||||
<declare-styleable name="PagerSlidingTabStrip">
|
||||
|
|
|
@ -1,9 +1,13 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<color name="actionbar_color">#ff8f00</color>
|
||||
<color name="actionbar_dark_color">#39464d</color>
|
||||
<color name="tool_bar_dark_color">#CC080B0D</color>
|
||||
<color name="actionbar_light_color">#ff8f00</color>
|
||||
<color name="tool_bar_light_color">#CC080B0D</color>
|
||||
|
||||
<color name="dashboard_descr_colol">#727272</color>
|
||||
<color name="dashboard_background">#eaeaea</color>
|
||||
<color name="dashboard_divider">#f0f0f0</color>
|
||||
<color name="dashboard_divider">#F0F0F0</color>
|
||||
<color name="dashboard_black">#212121</color>
|
||||
<color name="dashboard_blue">#536DFE</color>
|
||||
<color name="gpx_color_point">#cd2c33</color>
|
||||
|
@ -14,6 +18,7 @@
|
|||
<color name="gpx_time_span_color">#0080FF</color>
|
||||
|
||||
|
||||
|
||||
<color name="background_tab_pressed">#1AFFFFFF</color>
|
||||
|
||||
<color name="color_transparent">#00000000</color>
|
||||
|
|
|
@ -69,33 +69,42 @@
|
|||
<item name="expandable_category_color">@color/group_background</item>
|
||||
<item name="reset_image">@drawable/ic_action_delete_light</item> <!-- @drawable/a_1_navigation_cancel_light -->
|
||||
<item name="windowActionBarOverlay">true</item>
|
||||
<item name="bottomToolBarColor">@color/tool_bar_light_color</item>
|
||||
<item name="pstsTabBackground">@color/actionbar_light_color</item>
|
||||
<item name="actionBarStyle">@style/Widget.Styled.ActionBarLight</item>
|
||||
<item name="android:actionBarStyle">@style/Widget.Styled.ActionBarLight</item>
|
||||
</style>
|
||||
<style name="OsmandLightDarkActionBarTheme" parent="Theme.AppCompat.Light.DarkActionBar">
|
||||
<!--<item name="android:windowContentOverlay">@null</item>
|
||||
<item name="android:windowBackground">@color/activity_background</item>
|
||||
<item name="android:colorBackground">@color/activity_background</item>
|
||||
<item name="android:colorBackgroundCacheHint">?android:attr/colorBackground</item>
|
||||
<item name="android:textColor">@color/activity_text</item>
|
||||
<item name="android:textColorPrimary">@color/activity_text</item>
|
||||
<item name="android:textColorSecondary">@color/activity_text</item>
|
||||
<item name="android:textColorTertiary">@color/activity_text</item>
|
||||
<item name="android:listViewStyle">@style/OsmandListView</item>
|
||||
-->
|
||||
<item name="reset_image">@drawable/ic_action_delete_light</item> <!-- @drawable/a_1_navigation_cancel_light -->
|
||||
<item name="expandable_category_color">@color/group_background</item>
|
||||
<item name="actionBarStyle">@style/Widget.Styled.ActionBar</item>
|
||||
<item name="android:actionBarStyle">@style/Widget.Styled.ActionBar</item>
|
||||
</style>
|
||||
|
||||
<style name="OsmandDarkTheme" parent="Theme.AppCompat">
|
||||
<item name="reset_image">@drawable/ic_action_delete_dark</item> <!-- @drawable/a_1_navigation_cancel_dark -->
|
||||
<item name="expandable_category_color">?android:attr/colorBackground</item>
|
||||
<item name="android:spinnerStyle">@style/Widget.Spinner</item>
|
||||
<item name="windowActionBarOverlay">true</item>
|
||||
</style>
|
||||
|
||||
<style name="Widget.Styled.ActionBar" parent="Widget.AppCompat.Light.ActionBar.Solid.Inverse">
|
||||
<item name="background">@drawable/bg_striped</item>
|
||||
<item name="android:background">@drawable/bg_striped</item>
|
||||
<item name="android:spinnerStyle">@style/Widget.Spinner</item>
|
||||
<item name="windowActionBarOverlay">true</item>
|
||||
<item name="bottomToolBarColor">@color/tool_bar_dark_color</item>
|
||||
<item name="pstsTabBackground">@color/actionbar_dark_color</item>
|
||||
<item name="actionBarStyle">@style/Widget.Styled.ActionBarDark</item>
|
||||
<item name="android:actionBarStyle">@style/Widget.Styled.ActionBarDark</item>
|
||||
</style>
|
||||
|
||||
<style name="OsmandLightDarkActionBarTheme" parent="Theme.AppCompat.Light.DarkActionBar">
|
||||
<item name="reset_image">@drawable/ic_action_delete_light</item> <!-- @drawable/a_1_navigation_cancel_light -->
|
||||
<item name="expandable_category_color">@color/group_background</item>
|
||||
<item name="actionBarStyle">@style/Widget.Styled.ActionBarDark</item>
|
||||
<item name="android:actionBarStyle">@style/Widget.Styled.ActionBarDark</item>
|
||||
<item name="bottomToolBarColor">@color/tool_bar_dark_color</item>
|
||||
<item name="pstsTabBackground">@color/actionbar_dark_color</item>
|
||||
</style>
|
||||
|
||||
|
||||
|
||||
<style name="Widget.Styled.ActionBarDark" parent="Widget.AppCompat.Light.ActionBar.Solid.Inverse">
|
||||
<item name="background">@color/actionbar_dark_color</item>
|
||||
<item name="android:background">@color/actionbar_dark_color</item>
|
||||
</style>
|
||||
|
||||
<style name="Widget.Styled.ActionBarLight" parent="Widget.AppCompat.Light.ActionBar.Solid">
|
||||
<item name="background">@color/actionbar_light_color</item>
|
||||
<item name="android:background">@color/actionbar_light_color</item>
|
||||
</style>
|
||||
|
||||
<style name="Widget.Spinner" parent="android:Widget">
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package net.osmand.access;
|
||||
|
||||
|
||||
import net.osmand.plus.OsmandApplication;
|
||||
import net.osmand.plus.R;
|
||||
import net.osmand.plus.access.AccessibilityMode;
|
||||
import net.osmand.plus.access.RelativeDirectionStyle;
|
||||
|
@ -22,6 +23,7 @@ public class SettingsAccessibilityActivity extends SettingsBaseActivity {
|
|||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
((OsmandApplication) getApplication()).applyTheme(this);
|
||||
super.onCreate(savedInstanceState);
|
||||
getToolbar().setTitle(R.string.accessibility_preferences);
|
||||
PreferenceScreen grp = getPreferenceScreen();
|
||||
|
|
|
@ -43,6 +43,11 @@ public abstract class ActionBarPreferenceActivity extends PreferenceActivity {
|
|||
finish();
|
||||
}
|
||||
});
|
||||
if (((OsmandApplication)getApplication()).getSettings().isLightActionBar()){
|
||||
toolbar.setBackgroundColor(getResources().getColor(R.color.actionbar_light_color));
|
||||
} else {
|
||||
toolbar.setBackgroundColor(getResources().getColor(R.color.actionbar_dark_color));
|
||||
}
|
||||
getSpinner().setVisibility(View.GONE);
|
||||
setProgressVisibility(false);
|
||||
}
|
||||
|
|
|
@ -27,10 +27,6 @@ import android.widget.TabHost;
|
|||
import android.widget.TabHost.TabSpec;
|
||||
import android.widget.TabWidget;
|
||||
import android.widget.TextView;
|
||||
import net.osmand.plus.activities.search.SearchActivity;
|
||||
import net.osmand.plus.dashboard.DashDownloadMapsFragment;
|
||||
import net.osmand.plus.dashboard.DashUpdatesFragment;
|
||||
import net.osmand.plus.download.IndexItem;
|
||||
import net.osmand.plus.views.controls.PagerSlidingTabStrip;
|
||||
|
||||
/**
|
||||
|
@ -57,6 +53,7 @@ public class FavouritesActivity extends TabActivity {
|
|||
setSupportProgressBarIndeterminateVisibility(false);
|
||||
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
|
||||
getSupportActionBar().setTitle(R.string.favorites_Button);
|
||||
getSupportActionBar().setElevation(0);
|
||||
// getSupportActionBar().setTitle("");
|
||||
// getSupportActionBar().setIcon(R.drawable.tab_search_favorites_icon);
|
||||
File[] lf = ((OsmandApplication) getApplication()).getAppPath(TRACKS).listFiles();
|
||||
|
@ -74,7 +71,7 @@ public class FavouritesActivity extends TabActivity {
|
|||
setContentView(R.layout.search_activity_single);
|
||||
getSupportFragmentManager().beginTransaction().add(R.id.layout, new FavouritesTreeFragment()).commit();
|
||||
} else {
|
||||
setContentView(R.layout.search_main);
|
||||
setContentView(R.layout.tab_content);
|
||||
|
||||
PagerSlidingTabStrip mSlidingTabLayout = (PagerSlidingTabStrip) findViewById(R.id.sliding_tabs);
|
||||
OsmandSettings settings = ((OsmandApplication) getApplication()).getSettings();
|
||||
|
|
|
@ -4,6 +4,7 @@ package net.osmand.plus.activities;
|
|||
import java.io.File;
|
||||
|
||||
import net.osmand.IndexConstants;
|
||||
import net.osmand.plus.OsmandApplication;
|
||||
import net.osmand.plus.OsmandPlugin;
|
||||
import net.osmand.plus.R;
|
||||
import android.content.Intent;
|
||||
|
@ -33,6 +34,7 @@ public class SettingsActivity extends SettingsBaseActivity {
|
|||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
((OsmandApplication) getApplication()).applyTheme(this);
|
||||
super.onCreate(savedInstanceState);
|
||||
addPreferencesFromResource(R.xml.settings_pref);
|
||||
PreferenceScreen screen = getPreferenceScreen();
|
||||
|
|
|
@ -303,8 +303,6 @@ public abstract class SettingsBaseActivity extends ActionBarPreferenceActivity
|
|||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
((OsmandApplication) getApplication()).applyTheme(this);
|
||||
//getToolbar().setNavigationMode(ActionBar.NAVIGATION_MODE_STANDARD);
|
||||
|
||||
super.onCreate(savedInstanceState);
|
||||
getToolbar().setTitle(R.string.settings_activity);
|
||||
settings = getMyApplication().getSettings();
|
||||
|
@ -316,7 +314,6 @@ public abstract class SettingsBaseActivity extends ActionBarPreferenceActivity
|
|||
modes.add(a);
|
||||
}
|
||||
}
|
||||
//getToolbar().setNavigationMode(ActionBar.NAVIGATION_MODE_LIST);
|
||||
List<String> s = new ArrayList<String>();
|
||||
for (ApplicationMode a : modes) {
|
||||
s.add(a.toHumanString(getMyApplication()));
|
||||
|
|
|
@ -67,7 +67,7 @@ public class SettingsGeneralActivity extends SettingsBaseActivity {
|
|||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);
|
||||
((OsmandApplication) getApplication()).applyTheme(this);
|
||||
super.onCreate(savedInstanceState);
|
||||
getToolbar().setTitle(R.string.global_app_settings);
|
||||
addPreferencesFromResource(R.xml.general_settings);
|
||||
|
|
|
@ -5,13 +5,9 @@ import java.util.ArrayList;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import net.osmand.plus.ApplicationMode;
|
||||
import net.osmand.plus.DeviceAdminRecv;
|
||||
import net.osmand.plus.OsmandSettings;
|
||||
import net.osmand.plus.*;
|
||||
import net.osmand.plus.OsmandSettings.AutoZoomMap;
|
||||
import net.osmand.plus.OsmandSettings.OsmandPreference;
|
||||
import net.osmand.plus.R;
|
||||
import net.osmand.plus.Version;
|
||||
import net.osmand.plus.routing.RouteProvider.RouteService;
|
||||
import net.osmand.router.GeneralRouter;
|
||||
import net.osmand.router.GeneralRouter.RoutingParameter;
|
||||
|
@ -52,6 +48,7 @@ public class SettingsNavigationActivity extends SettingsBaseActivity {
|
|||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
((OsmandApplication) getApplication()).applyTheme(this);
|
||||
super.onCreate(savedInstanceState);
|
||||
getToolbar().setTitle(R.string.routing_settings);
|
||||
|
||||
|
|
|
@ -24,16 +24,11 @@ import net.osmand.plus.views.controls.PagerSlidingTabStrip;
|
|||
import net.osmand.util.Algorithms;
|
||||
import android.app.ActionBar;
|
||||
import android.content.Intent;
|
||||
import android.graphics.Color;
|
||||
import android.graphics.drawable.ColorDrawable;
|
||||
import android.os.Bundle;
|
||||
import android.support.v4.app.Fragment;
|
||||
import android.support.v4.app.FragmentManager;
|
||||
import android.support.v4.app.FragmentPagerAdapter;
|
||||
import android.support.v4.view.ViewPager;
|
||||
import android.support.v4.view.ViewPager.OnPageChangeListener;
|
||||
import android.support.v7.app.ActionBar.OnNavigationListener;
|
||||
import android.support.v7.app.ActionBarActivity;
|
||||
import android.support.v7.widget.Toolbar;
|
||||
import android.util.Log;
|
||||
import android.view.MenuItem;
|
||||
|
@ -41,8 +36,6 @@ import android.view.View;
|
|||
import android.widget.ArrayAdapter;
|
||||
import android.widget.Button;
|
||||
|
||||
import com.example.android.common.view.SlidingTabLayout;
|
||||
|
||||
public class SearchActivity extends TabActivity implements OsmAndLocationListener {
|
||||
public static final int POI_TAB_INDEX = 0;
|
||||
public static final int ADDRESS_TAB_INDEX = 1;
|
||||
|
@ -86,8 +79,7 @@ public class SearchActivity extends TabActivity implements OsmAndLocationListene
|
|||
((OsmandApplication) getApplication()).applyTheme(this);
|
||||
super.onCreate(savedInstanceState);
|
||||
long t = System.currentTimeMillis();
|
||||
getSupportActionBar().setNavigationMode(ActionBar.NAVIGATION_MODE_LIST);
|
||||
setContentView(R.layout.search_main);
|
||||
setContentView(R.layout.tab_content);
|
||||
settings = ((OsmandApplication) getApplication()).getSettings();
|
||||
Integer tab = settings.SEARCH_TAB.get();
|
||||
showOnlyOneTab = getIntent() != null && getIntent().getBooleanExtra(SHOW_ONLY_ONE_TAB, false);
|
||||
|
|
|
@ -17,6 +17,7 @@ import static net.osmand.plus.audionotes.AudioVideoNotesPlugin.AV_CAMERA_FOCUS_I
|
|||
import static net.osmand.plus.audionotes.AudioVideoNotesPlugin.AV_CAMERA_FOCUS_MACRO;
|
||||
import static net.osmand.plus.audionotes.AudioVideoNotesPlugin.AV_CAMERA_FOCUS_CONTINUOUS;
|
||||
////
|
||||
import net.osmand.plus.OsmandApplication;
|
||||
import org.apache.commons.logging.Log;
|
||||
import net.osmand.PlatformUtil;
|
||||
import java.util.List;
|
||||
|
@ -36,6 +37,7 @@ public class SettingsAudioVideoActivity extends SettingsBaseActivity {
|
|||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
((OsmandApplication) getApplication()).applyTheme(this);
|
||||
super.onCreate(savedInstanceState);
|
||||
getToolbar().setTitle(R.string.av_settings);
|
||||
PreferenceScreen grp = getPreferenceScreen();
|
||||
|
|
|
@ -20,7 +20,8 @@ import java.util.ArrayList;
|
|||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Created by Denis on 23.12.2014.
|
||||
* Created by Denis
|
||||
* on 23.12.2014.
|
||||
*/
|
||||
public class DashAudioVideoNotesActivity extends ActionBarActivity {
|
||||
AudioVideoNotesPlugin plugin;
|
||||
|
@ -33,17 +34,13 @@ public class DashAudioVideoNotesActivity extends ActionBarActivity {
|
|||
setContentView(R.layout.editing_poi_filter);
|
||||
|
||||
plugin = OsmandPlugin.getEnabledPlugin(AudioVideoNotesPlugin.class);
|
||||
int c = getResources().getColor(R.color.actionbar_color);
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP){
|
||||
Window window = getWindow();
|
||||
window.addFlags(WindowManager.LayoutParams.FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS);
|
||||
window.clearFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS);
|
||||
window.setStatusBarColor(c);
|
||||
}
|
||||
ColorDrawable color = new ColorDrawable(c);
|
||||
ActionBar actionBar = getSupportActionBar();
|
||||
actionBar.setTitle(R.string.audionotes_plugin_name);
|
||||
actionBar.setBackgroundDrawable(color);
|
||||
actionBar.setIcon(android.R.color.transparent);
|
||||
actionBar.setHomeButtonEnabled(true);
|
||||
actionBar.setDisplayHomeAsUpEnabled(true);
|
||||
|
|
|
@ -7,6 +7,7 @@ import java.util.List;
|
|||
import java.util.Set;
|
||||
|
||||
import net.osmand.plus.ApplicationMode;
|
||||
import net.osmand.plus.OsmandApplication;
|
||||
import net.osmand.plus.R;
|
||||
import net.osmand.plus.activities.SettingsBaseActivity;
|
||||
import net.osmand.plus.activities.actions.AppModeDialog;
|
||||
|
@ -30,6 +31,7 @@ public class SettingsDevelopmentActivity extends SettingsBaseActivity {
|
|||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
((OsmandApplication) getApplication()).applyTheme(this);
|
||||
super.onCreate(savedInstanceState);
|
||||
getToolbar().setTitle(R.string.debugging_and_development);
|
||||
PreferenceScreen cat = getPreferenceScreen();
|
||||
|
|
|
@ -14,7 +14,6 @@ import net.osmand.plus.OsmandApplication;
|
|||
import net.osmand.plus.OsmandPlugin;
|
||||
import net.osmand.plus.R;
|
||||
import net.osmand.plus.Version;
|
||||
import net.osmand.plus.activities.FavouritesActivity;
|
||||
import net.osmand.plus.activities.LocalIndexInfo;
|
||||
import net.osmand.plus.activities.TabActivity;
|
||||
import net.osmand.plus.base.BasicProgressAsyncTask;
|
||||
|
@ -28,11 +27,9 @@ import android.support.v4.app.Fragment;
|
|||
import android.support.v4.view.ViewPager;
|
||||
import android.view.MenuItem;
|
||||
import android.view.View;
|
||||
import android.view.Window;
|
||||
import android.widget.Button;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.ProgressBar;
|
||||
import android.widget.TabHost;
|
||||
import android.widget.TextView;
|
||||
import net.osmand.plus.views.controls.PagerSlidingTabStrip;
|
||||
|
||||
|
@ -70,12 +67,9 @@ public class DownloadActivity extends BaseDownloadActivity {
|
|||
protected void onCreate(Bundle savedInstanceState) {
|
||||
getMyApplication().applyTheme(this);
|
||||
super.onCreate(savedInstanceState);
|
||||
setupIntermediateProgressBar();
|
||||
updateDownloads();
|
||||
|
||||
|
||||
setContentView(R.layout.tab_content);
|
||||
findViewById(R.id.bottomControls).setVisibility(View.GONE);
|
||||
setContentView(R.layout.download);
|
||||
singleTab = getIntent() != null && getIntent().getBooleanExtra(SINGLE_TAB, false);
|
||||
int currentTab = 0;
|
||||
String tab = getIntent() == null || getIntent().getExtras() == null ? null : getIntent().getExtras().getString(TAB_TO_OPEN);
|
||||
|
|
|
@ -21,7 +21,8 @@ import java.util.List;
|
|||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* Created by Denis on 09.09.2014.
|
||||
* Created by Denis
|
||||
* on 09.09.2014.
|
||||
*/
|
||||
public class UpdatesIndexFragment extends ListFragment {
|
||||
|
||||
|
|
|
@ -4,6 +4,7 @@ package net.osmand.plus.monitoring;
|
|||
import android.view.Window;
|
||||
import net.osmand.plus.NavigationService;
|
||||
import net.osmand.plus.OsmAndTaskManager.OsmAndTaskRunnable;
|
||||
import net.osmand.plus.OsmandApplication;
|
||||
import net.osmand.plus.OsmandSettings;
|
||||
import net.osmand.plus.R;
|
||||
import net.osmand.plus.activities.SavingTrackHelper;
|
||||
|
@ -38,10 +39,10 @@ public class SettingsMonitoringActivity extends SettingsBaseActivity {
|
|||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);
|
||||
((OsmandApplication) getApplication()).applyTheme(this);
|
||||
requestWindowFeature(Window.FEATURE_PROGRESS);
|
||||
super.onCreate(savedInstanceState);
|
||||
//setSupportProgressBarIndeterminateVisibility(false);
|
||||
setProgressVisibility(false);
|
||||
getToolbar().setTitle(R.string.monitoring_settings);
|
||||
PreferenceScreen grp = getPreferenceScreen();
|
||||
|
||||
|
@ -121,7 +122,7 @@ public class SettingsMonitoringActivity extends SettingsBaseActivity {
|
|||
}
|
||||
|
||||
private void saveCurrentTracks(final SavingTrackHelper helper) {
|
||||
//setSupportProgressBarIndeterminateVisibility(true);
|
||||
setProgressVisibility(true);
|
||||
getMyApplication().getTaskManager().runInBackground(new OsmAndTaskRunnable<Void, Void, Void>() {
|
||||
|
||||
@Override
|
||||
|
@ -133,7 +134,7 @@ public class SettingsMonitoringActivity extends SettingsBaseActivity {
|
|||
}
|
||||
@Override
|
||||
protected void onPostExecute(Void result) {
|
||||
//setSupportProgressBarIndeterminateVisibility(false);
|
||||
setProgressVisibility(false);
|
||||
}
|
||||
|
||||
}, (Void) null);
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package net.osmand.plus.osmedit;
|
||||
|
||||
|
||||
import net.osmand.plus.OsmandApplication;
|
||||
import net.osmand.plus.R;
|
||||
import net.osmand.plus.activities.SettingsBaseActivity;
|
||||
import android.content.Intent;
|
||||
|
@ -17,6 +18,7 @@ public class SettingsOsmEditingActivity extends SettingsBaseActivity {
|
|||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
((OsmandApplication) getApplication()).applyTheme(this);
|
||||
super.onCreate(savedInstanceState);
|
||||
getToolbar().setTitle(R.string.osm_settings);
|
||||
PreferenceScreen grp = getPreferenceScreen();
|
||||
|
|
|
@ -4,6 +4,7 @@ package net.osmand.plus.osmo;
|
|||
import java.util.List;
|
||||
|
||||
import net.osmand.access.AccessibleToast;
|
||||
import net.osmand.plus.OsmandApplication;
|
||||
import net.osmand.plus.OsmandPlugin;
|
||||
import net.osmand.plus.R;
|
||||
import net.osmand.plus.activities.SettingsBaseActivity;
|
||||
|
@ -37,6 +38,7 @@ public class SettingsOsMoActivity extends SettingsBaseActivity {
|
|||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
((OsmandApplication) getApplication()).applyTheme(this);
|
||||
super.onCreate(savedInstanceState);
|
||||
getToolbar().setTitle(R.string.osmo_settings);
|
||||
PreferenceScreen grp = getPreferenceScreen();
|
||||
|
|
|
@ -5,6 +5,7 @@ import java.util.Map;
|
|||
|
||||
import net.osmand.ResultMatcher;
|
||||
import net.osmand.map.TileSourceManager.TileSourceTemplate;
|
||||
import net.osmand.plus.OsmandApplication;
|
||||
import net.osmand.plus.R;
|
||||
import net.osmand.plus.activities.SettingsBaseActivity;
|
||||
import net.osmand.plus.views.SeekBarPreference;
|
||||
|
@ -27,6 +28,7 @@ public class SettingsRasterMapsActivity extends SettingsBaseActivity {
|
|||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
((OsmandApplication) getApplication()).applyTheme(this);
|
||||
super.onCreate(savedInstanceState);
|
||||
getToolbar().setTitle(R.string.online_map_settings);
|
||||
PreferenceScreen grp = getPreferenceScreen();
|
||||
|
|
|
@ -115,7 +115,7 @@ public class SherpafyStageFragment extends Fragment {
|
|||
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
|
||||
view = inflater.inflate(R.layout.tab_content, container, false);
|
||||
view = inflater.inflate(R.layout.download, container, false);
|
||||
tabHost = (TabHost) view.findViewById(android.R.id.tabhost);
|
||||
tabHost.setup();
|
||||
|
||||
|
|
Loading…
Reference in a new issue