summaryrefslogtreecommitdiffstats
path: root/res
diff options
context:
space:
mode:
authorJoey <joey@lineageos.org>2018-02-04 11:36:32 +0100
committerJoey <joey@lineageos.org>2018-02-05 19:54:40 +0000
commit1b2f8875b149fa27f80b6945cb51a5476e709a8b (patch)
tree296e016387f4813a96aca6b6f92d7e60ef7704f9 /res
parent8463529145791249bb7118fe96482a5e8e58eac4 (diff)
downloadandroid_packages_apps_Trebuchet-1b2f8875b149fa27f80b6945cb51a5476e709a8b.zip
android_packages_apps_Trebuchet-1b2f8875b149fa27f80b6945cb51a5476e709a8b.tar.gz
android_packages_apps_Trebuchet-1b2f8875b149fa27f80b6945cb51a5476e709a8b.tar.bz2
Trebuchet: allow disabling workspace edit
Change-Id: I503e19cbc512eac0e4a8c8bccc16a6ccc0e805da Signed-off-by: Joey <joey@lineageos.org>
Diffstat (limited to 'res')
-rw-r--r--res/drawable/ic_settings_edit.xml25
-rw-r--r--res/values/lineage_strings.xml4
-rw-r--r--res/xml/launcher_preferences.xml9
3 files changed, 38 insertions, 0 deletions
diff --git a/res/drawable/ic_settings_edit.xml b/res/drawable/ic_settings_edit.xml
new file mode 100644
index 0000000..ff4b07f
--- /dev/null
+++ b/res/drawable/ic_settings_edit.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright (C) 2018 The LineageOS 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+ android:width="@dimen/settings_icon_size"
+ android:height="@dimen/settings_icon_size"
+ android:viewportHeight="24.0"
+ android:viewportWidth="24.0">
+ <path
+ android:fillColor="@color/settings_icons"
+ android:pathData="M3,17.25V21h3.75L17.81,9.94l-3.75,-3.75L3,17.25zM20.71,7.04c0.39,-0.39 0.39,-1.02 0,-1.41l-2.34,-2.34c-0.39,-0.39 -1.02,-0.39 -1.41,0l-1.83,1.83 3.75,3.75 1.83,-1.83z" />
+</vector>
diff --git a/res/values/lineage_strings.xml b/res/values/lineage_strings.xml
index 1b4564c..e4257ab 100644
--- a/res/values/lineage_strings.xml
+++ b/res/values/lineage_strings.xml
@@ -68,4 +68,8 @@
<string name="settings_icon_badging_desc_on">A bubble will be displayed above the icon when there\'s a notification</string>
<string name="settings_icon_badging_desc_off">No bubble will be displayed above the icon when there\'s a notification</string>
<string name="settings_feed">Enable feed integration</string>
+ <string name="settings_edit_allow_title">Allow edit</string>
+ <string name="settings_edit_allow_summary_on">Icons and widgets can be added, removed and moved on the homescreen</string>
+ <string name="settings_edit_allow_summary_off">Icons and widgets can\'t be added, removed and moved on the homescreen</string>
+ <string name="settings_edit_widgets_error">It\'s not possible to add widgets to the home screen</string>
</resources>
diff --git a/res/xml/launcher_preferences.xml b/res/xml/launcher_preferences.xml
index 03fc0ed..45f3b6e 100644
--- a/res/xml/launcher_preferences.xml
+++ b/res/xml/launcher_preferences.xml
@@ -14,6 +14,15 @@
-->
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
+ <SwitchPreference
+ android:defaultValue="true"
+ android:icon="@drawable/ic_settings_edit"
+ android:key="pref_workspace_edit"
+ android:persistent="true"
+ android:title="@string/settings_edit_allow_title"
+ android:summaryOn="@string/settings_edit_allow_summary_on"
+ android:summaryOff="@string/settings_edit_allow_summary_off" />
+
<PreferenceCategory
android:key="category_home"
android:title="@string/settings_category_home">