Slim recents [2/3]
@SKULSHADY: Cleanup, fixes and adapt for SettingsPreferenceFragment @rohanpurohit: bringup to 10 Change-Id: I7fa5703534c9eb76a555db9a6d3349cc2b6a2b2d Signed-off-by: rohan <purohit.rohan@gmail.com>
This commit is contained in:
@@ -18,4 +18,21 @@
|
||||
android:title="@string/recents_title"
|
||||
xmlns:settings="http://schemas.android.com/apk/res/com.android.settings">
|
||||
|
||||
<PreferenceCategory
|
||||
android:key="alternative_recents_category"
|
||||
android:title="@string/alternative_recents_category">
|
||||
|
||||
<Preference
|
||||
android:key="swipe_up_enabled_warning"
|
||||
android:selectable="false"
|
||||
android:summary="@string/alternative_recents_swipe_up_enabled_warning_summary" />
|
||||
|
||||
<com.cherish.settings.preferences.SystemSettingMasterSwitchPreference
|
||||
android:key="use_slim_recents"
|
||||
android:fragment="com.cherish.settings.fragments.SlimRecents"
|
||||
android:title="@string/slim_recents_fragment_title"
|
||||
android:summary="@string/slim_recents_fragment_summary"/>
|
||||
|
||||
</PreferenceCategory>
|
||||
|
||||
</PreferenceScreen>
|
||||
|
||||
23
res/xml/slim_recent_app_sidebar.xml
Normal file
23
res/xml/slim_recent_app_sidebar.xml
Normal file
@@ -0,0 +1,23 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
/**
|
||||
* Copyright (C) 2017 AICP
|
||||
*
|
||||
* 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.
|
||||
*/
|
||||
-->
|
||||
|
||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:title="@string/recent_app_sidebar_picker_title">
|
||||
|
||||
</PreferenceScreen>
|
||||
58
res/xml/slim_recent_app_sidebar_style.xml
Normal file
58
res/xml/slim_recent_app_sidebar_style.xml
Normal file
@@ -0,0 +1,58 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
/**
|
||||
* Copyright (C) 2017 AICP
|
||||
*
|
||||
* 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.
|
||||
*/
|
||||
-->
|
||||
|
||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:settings="http://schemas.android.com/apk/res/com.android.settings"
|
||||
android:title="@string/recent_app_sidebar_style_title">
|
||||
|
||||
<com.cherish.settings.preferences.SystemSettingSeekBarPreference
|
||||
android:key="recent_app_sidebar_scale_factor"
|
||||
android:title="@string/recent_app_sidebar_scale_title"
|
||||
android:defaultValue="100"
|
||||
android:max="160"
|
||||
settings:min="60"
|
||||
settings:interval="5"
|
||||
settings:units="%" />
|
||||
|
||||
<com.cherish.settings.preferences.SystemSettingSwitchPreference
|
||||
android:key="recent_app_sidebar_disable_labels"
|
||||
android:title="@string/recent_app_sidebar_hide_labels_title"
|
||||
android:disableDependentsState="true"
|
||||
android:defaultValue="false" />
|
||||
|
||||
<net.margaritov.preference.colorpicker.ColorPickerPreference
|
||||
android:key="recent_app_sidebar_text_color"
|
||||
android:title="@string/recent_app_sidebar_label_color_title"
|
||||
settings:defaultColorValue="0xffffffff"
|
||||
alphaSlider="false"
|
||||
android:dependency="recent_app_sidebar_disable_labels" />
|
||||
|
||||
<net.margaritov.preference.colorpicker.ColorPickerPreference
|
||||
android:key="recent_app_sidebar_bg_color"
|
||||
android:title="@string/recent_app_sidebar_bg_color_title"
|
||||
settings:defaultColorValue="0x00ffffff"
|
||||
alphaSlider="true" />
|
||||
|
||||
<com.cherish.settings.preferences.SystemSettingSwitchPreference
|
||||
android:key="recent_app_sidebar_open_simultaneously"
|
||||
android:title="@string/recent_app_sidebar_open_simultaneously_title"
|
||||
android:summary="@string/recent_app_sidebar_open_simultaneously_summary"
|
||||
android:defaultValue="true" />
|
||||
|
||||
</PreferenceScreen>
|
||||
150
res/xml/slim_recents.xml
Normal file
150
res/xml/slim_recents.xml
Normal file
@@ -0,0 +1,150 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
/**
|
||||
* Copyright (C) 2017 AICP
|
||||
*
|
||||
* 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.
|
||||
*/
|
||||
-->
|
||||
|
||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:settings="http://schemas.android.com/apk/res/com.android.settings"
|
||||
android:title="@string/slim_recents_title">
|
||||
|
||||
<com.cherish.settings.preferences.SystemSettingSeekBarPreference
|
||||
android:key="recent_panel_scale_factor"
|
||||
android:title="@string/recent_panel_scale_title"
|
||||
settings:min="60"
|
||||
settings:interval="5"
|
||||
android:max="160"
|
||||
android:defaultValue="100"
|
||||
settings:units="%" />
|
||||
|
||||
<net.margaritov.preference.colorpicker.ColorPickerPreference
|
||||
android:key="recent_panel_bg_color"
|
||||
android:title="@string/recent_panel_bg_color_title"
|
||||
settings:defaultColorValue="0x00ffffff"
|
||||
alphaSlider="true" />
|
||||
|
||||
<net.margaritov.preference.colorpicker.ColorPickerPreference
|
||||
android:key="recent_card_bg_color"
|
||||
android:title="@string/recent_card_bg_color_title"
|
||||
settings:defaultColorValue="0x00ffffff"
|
||||
alphaSlider="true" />
|
||||
|
||||
<com.cherish.settings.preferences.SystemSettingSeekBarPreference
|
||||
android:key="recents_max_apps"
|
||||
android:title="@string/recents_max_apps_title"
|
||||
android:defaultValue="15"
|
||||
settings:min="5"
|
||||
android:max="105" />
|
||||
|
||||
<SwitchPreference
|
||||
android:key="recent_panel_lefty_mode"
|
||||
android:title="@string/recent_panel_lefty_mode_title"
|
||||
android:summary="@string/recent_panel_lefty_mode_summary"
|
||||
android:defaultValue="false" />
|
||||
|
||||
<com.cherish.settings.preferences.SystemSettingListPreference
|
||||
android:key="slim_recent_enter_exit_animation"
|
||||
android:title="@string/slim_recents_enter_exit_animation_title"
|
||||
android:entries="@array/slim_recents_enter_exit_animation_entries"
|
||||
android:entryValues="@array/slim_recents_enter_exit_animation_values"
|
||||
android:defaultValue="0" />
|
||||
|
||||
<com.cherish.settings.preferences.SystemSettingSeekBarPreference
|
||||
android:key="slim_recents_corner_radius"
|
||||
android:title="@string/slim_recents_corner_radius_title"
|
||||
settings:min="0"
|
||||
android:max="20"
|
||||
android:defaultValue="8"
|
||||
settings:units="dp" />
|
||||
|
||||
<com.cherish.settings.preferences.SystemSettingListPreference
|
||||
android:key="recent_panel_expanded_mode"
|
||||
android:entries="@array/recent_panel_expanded_mode_entries"
|
||||
android:entryValues="@array/recent_panel_expanded_mode_values"
|
||||
android:title="@string/recent_panel_expanded_mode_title"
|
||||
android:summary="@string/recent_panel_expanded_mode_summary"
|
||||
android:defaultValue="0" />
|
||||
|
||||
<Preference
|
||||
android:key="slim_icon_pack"
|
||||
android:title="@string/slim_icon_pack_title"
|
||||
android:summary="@string/slim_icon_pack_summary" />
|
||||
|
||||
<PreferenceScreen
|
||||
android:key="blacklist_fragment"
|
||||
android:fragment="com.cherish.settings.fragments.SlimRecentsBlacklist"
|
||||
android:title="@string/slim_blacklist_apps_title"
|
||||
android:summary="@string/slim_blacklist_apps_summary" />
|
||||
|
||||
<PreferenceCategory
|
||||
android:title="@string/recent_app_sidebar_cat_title">
|
||||
|
||||
<com.cherish.settings.preferences.SystemSettingSwitchPreference
|
||||
android:key="use_recent_app_sidebar"
|
||||
android:title="@string/recent_app_sidebar_title"
|
||||
android:summary="@string/recent_app_sidebar_summary"
|
||||
android:defaultValue="true" />
|
||||
|
||||
<PreferenceScreen
|
||||
android:key="recent_app_sidebar"
|
||||
android:title="@string/recent_app_sidebar_picker_title"
|
||||
android:summary="@string/recent_app_sidebar_picker_summary"
|
||||
android:fragment="com.cherish.settings.preferences.dslv.ActionListViewSettings"
|
||||
android:dependency="use_recent_app_sidebar" >
|
||||
<extra android:name="actionMode" android:value="7" />
|
||||
<extra android:name="maxAllowedActions" android:value="-1" />
|
||||
<extra android:name="useAppPickerOnly" android:value="true" />
|
||||
<extra android:name="fragment" android:value="com.cherish.settings.fragments.SlimRecentAppSidebar" />
|
||||
</PreferenceScreen>
|
||||
|
||||
<PreferenceScreen
|
||||
android:key="recent_app_sidebar_fragment"
|
||||
android:fragment="com.cherish.settings.fragments.SlimRecentAppSidebarStyle"
|
||||
android:title="@string/recent_app_sidebar_style_title"
|
||||
android:summary="@string/recent_app_sidebar_style_summary"
|
||||
android:dependency="use_recent_app_sidebar" />
|
||||
</PreferenceCategory>
|
||||
|
||||
<PreferenceCategory
|
||||
android:title="@string/slim_recents_mem_display_category_title">
|
||||
|
||||
<com.cherish.settings.preferences.SystemSettingSwitchPreference
|
||||
android:key="slim_recents_mem_display"
|
||||
android:title="@string/slim_recents_mem_display_title"
|
||||
android:summary="@string/slim_recents_mem_display_summary"
|
||||
android:defaultValue="false" />
|
||||
|
||||
<com.cherish.settings.preferences.SystemSettingSwitchPreference
|
||||
android:key="slim_recents_mem_display_long_click_clear"
|
||||
android:title="@string/slim_recents_mem_display_long_click_clear_title"
|
||||
android:summary="@string/slim_recents_mem_display_long_click_clear_summary"
|
||||
android:defaultValue="false"
|
||||
android:dependency="slim_recents_mem_display" />
|
||||
|
||||
<net.margaritov.preference.colorpicker.ColorPickerPreference
|
||||
android:key="slim_mem_bar_color"
|
||||
android:title="@string/slim_recents_mem_display_color"
|
||||
settings:defaultColorValue="0xffffffff"
|
||||
android:dependency="slim_recents_mem_display"/>
|
||||
|
||||
<net.margaritov.preference.colorpicker.ColorPickerPreference
|
||||
android:key="slim_mem_text_color"
|
||||
android:title="@string/slim_recents_mem_display_text_color"
|
||||
settings:defaultColorValue="0xffffffff"
|
||||
android:dependency="slim_recents_mem_display"/>
|
||||
|
||||
</PreferenceCategory>
|
||||
</PreferenceScreen>
|
||||
27
res/xml/slim_recents_blacklist.xml
Normal file
27
res/xml/slim_recents_blacklist.xml
Normal file
@@ -0,0 +1,27 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Copyright (C) 2017 The ABC rom
|
||||
Copyright (C) 2017 AICP
|
||||
|
||||
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.
|
||||
-->
|
||||
|
||||
<PreferenceScreen
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:title="@string/slim_blacklist_apps_title">
|
||||
|
||||
<Preference
|
||||
android:key="add_blacklist_packages"
|
||||
android:title="@string/slim_blacklist_add_apps_title"
|
||||
android:summary="@string/slim_blacklist_add_apps_summary" />
|
||||
|
||||
</PreferenceScreen>
|
||||
Reference in New Issue
Block a user