Loading res/layout/storage_summary_donut.xml +0 −9 Original line number Diff line number Diff line Loading @@ -56,15 +56,6 @@ android:textAlignment="viewStart" android:textAppearance="@android:style/TextAppearance.Material.Body1" /> <TextView android:id="@+id/storage_manager_indicator" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_marginStart="4dp" android:layout_marginEnd="4dp" android:textAlignment="viewStart" android:textAppearance="@android:style/TextAppearance.Material.Body1"/> <Button android:id="@+id/deletion_helper_button" android:layout_width="wrap_content" Loading res/values/strings.xml +12 −12 Original line number Diff line number Diff line Loading @@ -8251,18 +8251,6 @@ <!-- The percent of storage used by a storage volume. Exposed inside of a donut graph. [CHAR LIMIT=4]--> <string name="storage_percent_used"><xliff:g id="percent" example="50%">%1$s</xliff:g>%%</string> <!-- Indicates if the automatic storage manager is enabled or not. [CHAR_LIMIT=40] --> <string name="storage_manager_indicator">Storage Manager: <xliff:g id="status" example="on">^1</xliff:g></string> <!-- Off status for the automatic storage manager. [CHAR_LIMIT=10] --> <string name="storage_manager_indicator_off">Off</string> <!-- On status for the automatic storage manager. [CHAR_LIMIT=10] --> <string name="storage_manager_indicator_on">On</string> <!-- Added as the value of a header field indicating this is an instant app (as opposed to installed normally) --> <string name="install_type_instant">Instant app</string> <!-- Title of games app storage screen [CHAR LIMIT=30] --> <string name="game_storage_settings">Games</string> Loading Loading @@ -8291,4 +8279,16 @@ <!-- Temporary reboot string, will be removed --> <string name="change_theme_reboot" translatable="false">Changing the theme requires a restart.</string> <!-- Indicates if the automatic storage manager is enabled or not. [CHAR_LIMIT=40] --> <string name="storage_manager_indicator">Storage Manager: <xliff:g id="status" example="on">^1</xliff:g></string> <!-- Off status for the automatic storage manager. [CHAR_LIMIT=10] --> <string name="storage_manager_indicator_off">Off</string> <!-- On status for the automatic storage manager. [CHAR_LIMIT=10] --> <string name="storage_manager_indicator_on">On</string> <!-- Added as the value of a header field indicating this is an instant app (as opposed to installed normally) --> <string name="install_type_instant">Instant app</string> </resources> res/xml/storage_dashboard_fragment.xml +12 −19 Original line number Diff line number Diff line Loading @@ -21,45 +21,38 @@ <com.android.settings.deviceinfo.storage.StorageSummaryDonutPreference android:key="pref_summary" android:order="0" /> <com.android.settings.widget.MasterSwitchPreference android:fragment="com.android.settings.deletionhelper.AutomaticStorageManagerSettings" android:key="toggle_asm" android:title="@string/automatic_storage_manager_preference_title" android:icon="@drawable/ic_settings_storage" android:order="1" /> <com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate android:key="pref_photos_videos" android:title="@string/storage_photos_videos" android:order="1" > </com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate> android:order="2" /> <com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate android:key="pref_music_audio" android:title="@string/storage_music_audio" android:order="2" > </com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate> android:order="3" /> <com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate android:key="pref_games" android:title="@string/storage_games" android:order="3" > </com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate> android:order="4" /> <com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate android:key="pref_other_apps" android:title="@string/storage_other_apps" android:order="4" > </com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate> android:order="5" /> <com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate android:key="pref_files" android:title="@string/storage_files" android:order="5" > </com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate> android:order="6" /> <com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate android:key="pref_system" android:title="@string/storage_detail_system" android:order="100" > </com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate> android:order="100" /> <PreferenceCategory android:key="pref_secondary_users" android:title="@string/storage_other_users" android:order="200" /> <Preference android:key="manage_storage" android:title="@string/storage_menu_manage" android:icon="@drawable/ic_settings_storage" android:fragment="com.android.settings.deletionhelper.AutomaticStorageManagerSettings" android:order="300" > </Preference> </PreferenceScreen> No newline at end of file src/com/android/settings/deletionhelper/AutomaticStorageManagerSettings.java +1 −0 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ package com.android.settings.deletionhelper; import android.app.Activity; import android.app.AlertDialog; import android.app.FragmentManager; import android.content.ContentResolver; import android.content.Intent; import android.os.Bundle; Loading src/com/android/settings/deviceinfo/ManageStoragePreferenceController.javadeleted 100644 → 0 +0 −41 Original line number Diff line number Diff line /* * Copyright (C) 2016 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.android.settings.deviceinfo; import android.content.Context; import com.android.settings.R; import com.android.settings.core.PreferenceController; public class ManageStoragePreferenceController extends PreferenceController { public static final String KEY_MANAGE_STORAGE = "manage_storage"; public ManageStoragePreferenceController(Context context) { super(context); } @Override public String getPreferenceKey() { return KEY_MANAGE_STORAGE; } @Override public boolean isAvailable() { return mContext.getResources().getBoolean(R.bool.config_storage_manager_settings_enabled); } } Loading
res/layout/storage_summary_donut.xml +0 −9 Original line number Diff line number Diff line Loading @@ -56,15 +56,6 @@ android:textAlignment="viewStart" android:textAppearance="@android:style/TextAppearance.Material.Body1" /> <TextView android:id="@+id/storage_manager_indicator" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_marginStart="4dp" android:layout_marginEnd="4dp" android:textAlignment="viewStart" android:textAppearance="@android:style/TextAppearance.Material.Body1"/> <Button android:id="@+id/deletion_helper_button" android:layout_width="wrap_content" Loading
res/values/strings.xml +12 −12 Original line number Diff line number Diff line Loading @@ -8251,18 +8251,6 @@ <!-- The percent of storage used by a storage volume. Exposed inside of a donut graph. [CHAR LIMIT=4]--> <string name="storage_percent_used"><xliff:g id="percent" example="50%">%1$s</xliff:g>%%</string> <!-- Indicates if the automatic storage manager is enabled or not. [CHAR_LIMIT=40] --> <string name="storage_manager_indicator">Storage Manager: <xliff:g id="status" example="on">^1</xliff:g></string> <!-- Off status for the automatic storage manager. [CHAR_LIMIT=10] --> <string name="storage_manager_indicator_off">Off</string> <!-- On status for the automatic storage manager. [CHAR_LIMIT=10] --> <string name="storage_manager_indicator_on">On</string> <!-- Added as the value of a header field indicating this is an instant app (as opposed to installed normally) --> <string name="install_type_instant">Instant app</string> <!-- Title of games app storage screen [CHAR LIMIT=30] --> <string name="game_storage_settings">Games</string> Loading Loading @@ -8291,4 +8279,16 @@ <!-- Temporary reboot string, will be removed --> <string name="change_theme_reboot" translatable="false">Changing the theme requires a restart.</string> <!-- Indicates if the automatic storage manager is enabled or not. [CHAR_LIMIT=40] --> <string name="storage_manager_indicator">Storage Manager: <xliff:g id="status" example="on">^1</xliff:g></string> <!-- Off status for the automatic storage manager. [CHAR_LIMIT=10] --> <string name="storage_manager_indicator_off">Off</string> <!-- On status for the automatic storage manager. [CHAR_LIMIT=10] --> <string name="storage_manager_indicator_on">On</string> <!-- Added as the value of a header field indicating this is an instant app (as opposed to installed normally) --> <string name="install_type_instant">Instant app</string> </resources>
res/xml/storage_dashboard_fragment.xml +12 −19 Original line number Diff line number Diff line Loading @@ -21,45 +21,38 @@ <com.android.settings.deviceinfo.storage.StorageSummaryDonutPreference android:key="pref_summary" android:order="0" /> <com.android.settings.widget.MasterSwitchPreference android:fragment="com.android.settings.deletionhelper.AutomaticStorageManagerSettings" android:key="toggle_asm" android:title="@string/automatic_storage_manager_preference_title" android:icon="@drawable/ic_settings_storage" android:order="1" /> <com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate android:key="pref_photos_videos" android:title="@string/storage_photos_videos" android:order="1" > </com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate> android:order="2" /> <com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate android:key="pref_music_audio" android:title="@string/storage_music_audio" android:order="2" > </com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate> android:order="3" /> <com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate android:key="pref_games" android:title="@string/storage_games" android:order="3" > </com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate> android:order="4" /> <com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate android:key="pref_other_apps" android:title="@string/storage_other_apps" android:order="4" > </com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate> android:order="5" /> <com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate android:key="pref_files" android:title="@string/storage_files" android:order="5" > </com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate> android:order="6" /> <com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate android:key="pref_system" android:title="@string/storage_detail_system" android:order="100" > </com.android.settings.deviceinfo.storage.StorageItemPreferenceAlternate> android:order="100" /> <PreferenceCategory android:key="pref_secondary_users" android:title="@string/storage_other_users" android:order="200" /> <Preference android:key="manage_storage" android:title="@string/storage_menu_manage" android:icon="@drawable/ic_settings_storage" android:fragment="com.android.settings.deletionhelper.AutomaticStorageManagerSettings" android:order="300" > </Preference> </PreferenceScreen> No newline at end of file
src/com/android/settings/deletionhelper/AutomaticStorageManagerSettings.java +1 −0 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ package com.android.settings.deletionhelper; import android.app.Activity; import android.app.AlertDialog; import android.app.FragmentManager; import android.content.ContentResolver; import android.content.Intent; import android.os.Bundle; Loading
src/com/android/settings/deviceinfo/ManageStoragePreferenceController.javadeleted 100644 → 0 +0 −41 Original line number Diff line number Diff line /* * Copyright (C) 2016 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.android.settings.deviceinfo; import android.content.Context; import com.android.settings.R; import com.android.settings.core.PreferenceController; public class ManageStoragePreferenceController extends PreferenceController { public static final String KEY_MANAGE_STORAGE = "manage_storage"; public ManageStoragePreferenceController(Context context) { super(context); } @Override public String getPreferenceKey() { return KEY_MANAGE_STORAGE; } @Override public boolean isAvailable() { return mContext.getResources().getBoolean(R.bool.config_storage_manager_settings_enabled); } }