summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorcretin45 <cretin45@gmail.com>2016-02-10 14:47:46 -0800
committercretin45 <cretin45@gmail.com>2016-02-10 14:48:58 -0800
commit6d81d82d9a8a1eae4b7221d77b0252b28a134b48 (patch)
treed4117a555839416f0ec405219de7a662afe71348 /src
parentadcd3cc2f909145ce54458bcd0505249ba22ef10 (diff)
downloadandroid_packages_apps_Trebuchet-6d81d82d9a8a1eae4b7221d77b0252b28a134b48.zip
android_packages_apps_Trebuchet-6d81d82d9a8a1eae4b7221d77b0252b28a134b48.tar.gz
android_packages_apps_Trebuchet-6d81d82d9a8a1eae4b7221d77b0252b28a134b48.tar.bz2
Trebuchet: Move allow rotation to home settings section
Issue-id: CYNGNOS-1929 Change-Id: Ib1e615ccbce7991a31e15a967c942994fc3c01c2
Diffstat (limited to 'src')
-rw-r--r--src/com/android/launcher3/OverviewSettingsPanel.java6
-rw-r--r--src/com/android/launcher3/list/SettingsPinnedHeaderAdapter.java22
2 files changed, 14 insertions, 14 deletions
diff --git a/src/com/android/launcher3/OverviewSettingsPanel.java b/src/com/android/launcher3/OverviewSettingsPanel.java
index 815a5c8..8f1b435 100644
--- a/src/com/android/launcher3/OverviewSettingsPanel.java
+++ b/src/com/android/launcher3/OverviewSettingsPanel.java
@@ -40,8 +40,7 @@ public class OverviewSettingsPanel {
String[] valuesApp = new String[] {
res.getString(R.string.larger_icons_text),
- res.getString(R.string.protected_app_settings),
- res.getString(R.string.allow_rotation_title)};
+ res.getString(R.string.protected_app_settings)};
mSettingsAdapter = new SettingsPinnedHeaderAdapter(mLauncher);
mSettingsAdapter.setHeaders(headers);
@@ -73,7 +72,8 @@ public class OverviewSettingsPanel {
res.getString(R.string.home_screen_search_text),
res.getString(R.string.icon_labels),
res.getString(R.string.scrolling_wallpaper),
- res.getString(R.string.grid_size_text)}));
+ res.getString(R.string.grid_size_text),
+ res.getString(R.string.allow_rotation_title)}));
// Add additional external settings.
RemoteFolderManager.onInitializeHomeSettings(values, mLauncher);
diff --git a/src/com/android/launcher3/list/SettingsPinnedHeaderAdapter.java b/src/com/android/launcher3/list/SettingsPinnedHeaderAdapter.java
index 18d396a..736b523 100644
--- a/src/com/android/launcher3/list/SettingsPinnedHeaderAdapter.java
+++ b/src/com/android/launcher3/list/SettingsPinnedHeaderAdapter.java
@@ -124,6 +124,12 @@ public class SettingsPinnedHeaderAdapter extends PinnedHeaderListAdapter {
break;
case 4:
current = SettingsProvider.getBoolean(mContext,
+ SettingsProvider.SETTINGS_UI_ALLOW_ROTATION,
+ R.bool.preferences_interface_allow_rotation);
+ setSettingSwitch(stateView, settingSwitch, current);
+ break;
+ case 5:
+ current = SettingsProvider.getBoolean(mContext,
SettingsProvider.SETTINGS_UI_HOMESCREEN_REMOTE_FOLDER,
R.bool.preferences_interface_homescreen_remote_folder_default);
setSettingSwitch(stateView, settingSwitch, current);
@@ -195,12 +201,6 @@ public class SettingsPinnedHeaderAdapter extends PinnedHeaderListAdapter {
R.bool.preferences_interface_general_icons_large_default);
setSettingSwitch(stateView, settingSwitch, current);
break;
- case 2:
- current = SettingsProvider.getBoolean(mContext,
- SettingsProvider.SETTINGS_UI_ALLOW_ROTATION,
- R.bool.preferences_interface_allow_rotation);
- setSettingSwitch(stateView, settingSwitch, current);
- break;
default:
hideStates(stateView, settingSwitch);
}
@@ -282,6 +282,11 @@ public class SettingsPinnedHeaderAdapter extends PinnedHeaderListAdapter {
break;
case 4:
onSettingsBooleanChanged(v,
+ SettingsProvider.SETTINGS_UI_ALLOW_ROTATION,
+ R.bool.preferences_interface_allow_rotation);
+ break;
+ case 5:
+ onSettingsBooleanChanged(v,
SettingsProvider.SETTINGS_UI_HOMESCREEN_REMOTE_FOLDER,
R.bool.preferences_interface_homescreen_remote_folder_default);
mLauncher.getRemoteFolderManager().onSettingChanged();
@@ -350,11 +355,6 @@ public class SettingsPinnedHeaderAdapter extends PinnedHeaderListAdapter {
OverviewSettingsPanel.ANDROID_PROTECTED_APPS);
mLauncher.startActivity(intent);
break;
- case 2:
- onSettingsBooleanChanged(v,
- SettingsProvider.SETTINGS_UI_ALLOW_ROTATION,
- R.bool.preferences_interface_allow_rotation);
- break;
}
}