summaryrefslogtreecommitdiffstats
path: root/res
diff options
context:
space:
mode:
authorAmith Yamasani <yamasani@google.com>2011-06-21 13:03:34 -0700
committerAmith Yamasani <yamasani@google.com>2011-06-22 11:29:38 -0700
commit6be594922fac988f3b350718df8e9df3ef25b97e (patch)
tree7352b5679222d26d849eb15bb5694defc81baa79 /res
parent2a451abcc0d81d249840ca755d54ae829002d27e (diff)
downloadandroid_packages_apps_Trebuchet-6be594922fac988f3b350718df8e9df3ef25b97e.tar.gz
android_packages_apps_Trebuchet-6be594922fac988f3b350718df8e9df3ef25b97e.tar.bz2
android_packages_apps_Trebuchet-6be594922fac988f3b350718df8e9df3ef25b97e.zip
A fullscreen wallpaper chooser for all screen sizes.
The wallpaper preview covers the whole screen, with background protection for the gallery items and button. Change-Id: Ice31c4fea6503d1a59b59d6fbffb5e4a28eb2143
Diffstat (limited to 'res')
-rw-r--r--res/drawable/wallpaper_gallery_background.xml20
-rw-r--r--res/layout-large/wallpaper_chooser.xml51
-rw-r--r--res/layout-large/wallpaper_chooser_base.xml23
-rw-r--r--res/layout/wallpaper_chooser.xml36
-rw-r--r--res/values-large/styles.xml11
-rw-r--r--res/values/styles.xml8
6 files changed, 44 insertions, 105 deletions
diff --git a/res/drawable/wallpaper_gallery_background.xml b/res/drawable/wallpaper_gallery_background.xml
new file mode 100644
index 000000000..271c1dfb8
--- /dev/null
+++ b/res/drawable/wallpaper_gallery_background.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2011 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.
+-->
+
+<shape xmlns:android="http://schemas.android.com/apk/res/android">
+ <gradient android:startColor="#0000" android:endColor="#D0000000"
+ android:angle="270"/>
+</shape> \ No newline at end of file
diff --git a/res/layout-large/wallpaper_chooser.xml b/res/layout-large/wallpaper_chooser.xml
deleted file mode 100644
index b48dbd9ad..000000000
--- a/res/layout-large/wallpaper_chooser.xml
+++ /dev/null
@@ -1,51 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/*
-**
-** Copyright 2010, 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.
-*/
--->
-
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:id="@+id/wallpaper_list"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:paddingLeft="24dp"
- android:paddingRight="24dp"
- android:paddingTop="24dp"
- android:paddingBottom="24dp"
- android:gravity="center">
- <GridView
- android:id="@+id/gallery"
- android:layout_width="636dp"
- android:layout_height="wrap_content"
- android:layout_gravity="center"
- android:numColumns="3"
- android:stretchMode="none"
- android:columnWidth="@dimen/live_wallpaper_column_width"
- android:verticalSpacing="0dp"
- android:horizontalSpacing="0dp"
- android:drawSelectorOnTop="false" />
- <TextView
- android:id="@android:id/empty"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
-
- android:gravity="center"
- android:visibility="gone"
-
- android:text="@string/wallpaper_chooser_empty"
- android:textAppearance="?android:attr/textAppearanceMedium" />
-</FrameLayout> \ No newline at end of file
diff --git a/res/layout-large/wallpaper_chooser_base.xml b/res/layout-large/wallpaper_chooser_base.xml
deleted file mode 100644
index ba5ac5304..000000000
--- a/res/layout-large/wallpaper_chooser_base.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/*
-**
-** Copyright 2010, 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.
-*/
--->
-
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content" />
diff --git a/res/layout/wallpaper_chooser.xml b/res/layout/wallpaper_chooser.xml
index 92a6596ee..c0a5fdf9e 100644
--- a/res/layout/wallpaper_chooser.xml
+++ b/res/layout/wallpaper_chooser.xml
@@ -18,26 +18,26 @@
*/
-->
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:orientation="vertical"
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent">
- <ImageView android:id="@+id/wallpaper"
- android:layout_width="match_parent"
- android:layout_height="0dip"
- android:layout_weight="1.0"
- android:scaleType="fitCenter" />
+ <LinearLayout
+ android:orientation="vertical"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_alignParentBottom="true"
+ android:background="@drawable/wallpaper_gallery_background">
- <Gallery android:id="@+id/gallery"
- android:layout_width="match_parent"
- android:layout_height="wrap_content" />
-
- <Button android:id="@+id/set"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:text="@string/wallpaper_instructions"
- android:layout_gravity="center_horizontal" />
-
-</LinearLayout>
+ <Gallery android:id="@+id/gallery"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content" />
+
+ <Button android:id="@+id/set"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="@string/wallpaper_instructions"
+ android:layout_gravity="center_horizontal" />
+ </LinearLayout>
+</RelativeLayout>
diff --git a/res/values-large/styles.xml b/res/values-large/styles.xml
index 7e19e89fa..f44bfa58a 100644
--- a/res/values-large/styles.xml
+++ b/res/values-large/styles.xml
@@ -18,9 +18,6 @@
-->
<resources>
- <style name="Theme.WallpaperPicker" parent="@*android:Theme.Holo.Dialog.NoFrame">
- </style>
-
<style name="Theme" parent="android:Theme.Holo">
<item name="android:windowNoTitle">true</item>
<item name="android:windowActionModeOverlay">true</item>
@@ -30,6 +27,10 @@
<item name="android:windowShowWallpaper">true</item>
</style>
+ <style name="Theme.WallpaperPicker">
+ <item name="android:screenOrientation">unspecified</item>
+ </style>
+
<style name="WorkspaceIcon.Portrait">
<item name="android:drawablePadding">2dip</item>
<item name="android:paddingTop">0dip</item>
@@ -83,8 +84,4 @@
<item name="android:textColor">#FFFFFFFF</item>
<item name="android:textSize">16sp</item>
</style>
-
- <style name="config_orientation">
- <item name="@android:screenOrientation">unspecified</item>
- </style>
</resources>
diff --git a/res/values/styles.xml b/res/values/styles.xml
index 3c0ae8d46..0449b9349 100644
--- a/res/values/styles.xml
+++ b/res/values/styles.xml
@@ -18,8 +18,8 @@
-->
<resources>
- <style name="Theme.WallpaperPicker" parent="android:Theme">
- <item name="android:windowNoTitle">true</item>
+ <style name="Theme.WallpaperPicker">
+ <item name="android:screenOrientation">nosensor</item>
</style>
<style name="Theme.Base" parent="android:Theme.Wallpaper">
@@ -155,8 +155,4 @@
<item name="android:layout_marginRight">4dip</item>
<item name="android:background">@drawable/hotseat_bg_right</item>
</style>
-
- <style name="config_orientation">
- <item name="@android:screenOrientation">nosensor</item>
- </style>
</resources>