summaryrefslogtreecommitdiffstats
path: root/res
diff options
context:
space:
mode:
authorMichael Jurka <mikejurka@google.com>2013-09-10 13:39:59 +0200
committerMichael Jurka <mikejurka@google.com>2013-09-12 20:49:17 +0200
commitd6dc6043ad29c84511b7cd1c60a4bb72279fb50a (patch)
tree1d24d27a2d63fbbab204b536435b590663bc8c65 /res
parentbe2f8ddd8067d0da71e2d03e42bcad17f9430439 (diff)
downloadandroid_packages_apps_Trebuchet-d6dc6043ad29c84511b7cd1c60a4bb72279fb50a.tar.gz
android_packages_apps_Trebuchet-d6dc6043ad29c84511b7cd1c60a4bb72279fb50a.tar.bz2
android_packages_apps_Trebuchet-d6dc6043ad29c84511b7cd1c60a4bb72279fb50a.zip
Adding ability to delete previously saved wallpapers
- Also preserving temporarily picked wallpapers on rotation Change-Id: I35361e2a5619cd986bd8b66268ce9e94b9a0027e
Diffstat (limited to 'res')
-rw-r--r--res/drawable/wallpaper_gallery_item.xml1
-rw-r--r--res/layout/wallpaper_picker_gallery_item.xml5
-rw-r--r--res/layout/wallpaper_picker_item.xml5
-rw-r--r--res/menu/cab_delete_wallpapers.xml27
-rw-r--r--res/values/strings.xml11
5 files changed, 45 insertions, 4 deletions
diff --git a/res/drawable/wallpaper_gallery_item.xml b/res/drawable/wallpaper_gallery_item.xml
index b7052bd39..9ac931b58 100644
--- a/res/drawable/wallpaper_gallery_item.xml
+++ b/res/drawable/wallpaper_gallery_item.xml
@@ -15,6 +15,7 @@
-->
<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:state_checked="true" android:drawable="@drawable/grid_pressed" />
<item android:state_focused="true" android:drawable="@drawable/grid_focused" />
<item android:state_pressed="true" android:drawable="@drawable/grid_pressed" />
<item android:state_selected="true" android:drawable="@drawable/grid_selected" />
diff --git a/res/layout/wallpaper_picker_gallery_item.xml b/res/layout/wallpaper_picker_gallery_item.xml
index b42b98afb..7f30f8040 100644
--- a/res/layout/wallpaper_picker_gallery_item.xml
+++ b/res/layout/wallpaper_picker_gallery_item.xml
@@ -14,7 +14,8 @@
limitations under the License.
-->
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<com.android.launcher3.CheckableFrameLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="@dimen/wallpaperThumbnailWidth"
android:layout_height="@dimen/wallpaperThumbnailHeight"
android:focusable="true"
@@ -33,4 +34,4 @@
android:layout_height="wrap_content"
android:layout_gravity="center"
android:textColor="#FFFFFFFF"/>
-</FrameLayout>
+</com.android.launcher3.CheckableFrameLayout>
diff --git a/res/layout/wallpaper_picker_item.xml b/res/layout/wallpaper_picker_item.xml
index c73bd73f2..06f01c94d 100644
--- a/res/layout/wallpaper_picker_item.xml
+++ b/res/layout/wallpaper_picker_item.xml
@@ -14,7 +14,8 @@
limitations under the License.
-->
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<com.android.launcher3.CheckableFrameLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="@dimen/wallpaperThumbnailWidth"
android:layout_height="@dimen/wallpaperThumbnailHeight"
android:focusable="true"
@@ -26,4 +27,4 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="fitXY" />
-</FrameLayout>
+</com.android.launcher3.CheckableFrameLayout>
diff --git a/res/menu/cab_delete_wallpapers.xml b/res/menu/cab_delete_wallpapers.xml
new file mode 100644
index 000000000..38ac5c4d6
--- /dev/null
+++ b/res/menu/cab_delete_wallpapers.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+**
+** Copyright 2013, 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.
+*/
+-->
+
+<menu xmlns:android="http://schemas.android.com/apk/res/android" >
+ <item
+ android:id="@+id/menu_delete"
+ android:title="@string/wallpaper_delete"
+ android:showAsAction="always"
+ android:icon="@android:drawable/ic_menu_delete" />
+</menu>
diff --git a/res/values/strings.xml b/res/values/strings.xml
index aeae48b24..bd803c64e 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -30,6 +30,17 @@
<string name="folder_name"></string>
<!-- Button label on Wallpaper picker screen; user selects this button to set a specific wallpaper -->
<string name="wallpaper_instructions">Set wallpaper</string>
+ <!-- Shown when wallpapers are selected in Wallpaper picker -->
+ <!-- String indicating how many media item(s) is(are) selected
+ eg. 1 selected [CHAR LIMIT=30] -->
+ <plurals name="number_of_items_selected">
+ <item quantity="zero">%1$d selected</item>
+ <item quantity="one">%1$d selected</item>
+ <item quantity="other">%1$d selected</item>
+ </plurals>
+
+ <!-- Label on button to delete wallpaper(s) -->
+ <string name="wallpaper_delete">Delete</string>
<!-- Label on button in Wallpaper Picker that launches Gallery app -->
<string name="gallery">Gallery</string>
<!-- Option in "Select wallpaper from" dialog box -->