summaryrefslogtreecommitdiffstats
path: root/res
diff options
context:
space:
mode:
authorHung-ying Tyan <tyanh@google.com>2010-12-09 20:20:27 +0800
committerHung-ying Tyan <tyanh@google.com>2010-12-10 16:47:32 +0800
commit373d10b91c8e736275a0bc52e247598eec0b3cea (patch)
tree4a0212cbe430636ea52c8ad4d18cfd49be970337 /res
parent9bbd157589ef9ee4a525bc8bc49586c8ba45b3ae (diff)
downloadpackages_apps_LegacyCamera-373d10b91c8e736275a0bc52e247598eec0b3cea.zip
packages_apps_LegacyCamera-373d10b91c8e736275a0bc52e247598eec0b3cea.tar.gz
packages_apps_LegacyCamera-373d10b91c8e736275a0bc52e247598eec0b3cea.tar.bz2
Implement photo/video picker mode using holo controls
Bug: 3253016 Change-Id: I0f851f2840cf1303c06921549028dcbf73d53b61
Diffstat (limited to 'res')
-rw-r--r--res/drawable-hdpi/ic_menu_cancel_holo_light.pngbin0 -> 605 bytes
-rw-r--r--res/drawable-hdpi/ic_menu_divider.pngbin0 -> 214 bytes
-rw-r--r--res/drawable-hdpi/ic_menu_done_holo_light.pngbin0 -> 562 bytes
-rw-r--r--res/drawable-hdpi/ic_switch_camera_holo_dark.pngbin0 -> 1442 bytes
-rw-r--r--res/drawable-hdpi/ic_switch_video_holo_dark.pngbin0 -> 1233 bytes
-rw-r--r--res/drawable-mdpi/ic_menu_cancel_holo_light.pngbin0 -> 605 bytes
-rw-r--r--res/drawable-mdpi/ic_menu_divider.pngbin0 -> 214 bytes
-rw-r--r--res/drawable-mdpi/ic_menu_done_holo_light.pngbin0 -> 562 bytes
-rw-r--r--res/drawable-mdpi/ic_switch_camera_holo_dark.pngbin0 -> 1442 bytes
-rw-r--r--res/drawable-mdpi/ic_switch_video_holo_dark.pngbin0 -> 1233 bytes
-rwxr-xr-xres/drawable-xlarge-mdpi/btn_ic_review_play.pngbin0 -> 1229 bytes
-rw-r--r--res/drawable-xlarge/btn_review_control.xml21
-rw-r--r--res/layout-xlarge/camera_control.xml1
-rw-r--r--res/layout-xlarge/preview_frame.xml5
-rw-r--r--res/layout-xlarge/preview_frame_video.xml13
-rw-r--r--res/layout-xlarge/review_control.xml58
-rw-r--r--res/values-xlarge/styles.xml13
-rw-r--r--res/values/colors.xml1
-rw-r--r--res/values/strings.xml8
19 files changed, 78 insertions, 42 deletions
diff --git a/res/drawable-hdpi/ic_menu_cancel_holo_light.png b/res/drawable-hdpi/ic_menu_cancel_holo_light.png
new file mode 100644
index 0000000..cb9abb9
--- /dev/null
+++ b/res/drawable-hdpi/ic_menu_cancel_holo_light.png
Binary files differ
diff --git a/res/drawable-hdpi/ic_menu_divider.png b/res/drawable-hdpi/ic_menu_divider.png
new file mode 100644
index 0000000..d6ded3d
--- /dev/null
+++ b/res/drawable-hdpi/ic_menu_divider.png
Binary files differ
diff --git a/res/drawable-hdpi/ic_menu_done_holo_light.png b/res/drawable-hdpi/ic_menu_done_holo_light.png
new file mode 100644
index 0000000..fb56f3a
--- /dev/null
+++ b/res/drawable-hdpi/ic_menu_done_holo_light.png
Binary files differ
diff --git a/res/drawable-hdpi/ic_switch_camera_holo_dark.png b/res/drawable-hdpi/ic_switch_camera_holo_dark.png
new file mode 100644
index 0000000..f417d34
--- /dev/null
+++ b/res/drawable-hdpi/ic_switch_camera_holo_dark.png
Binary files differ
diff --git a/res/drawable-hdpi/ic_switch_video_holo_dark.png b/res/drawable-hdpi/ic_switch_video_holo_dark.png
new file mode 100644
index 0000000..8488819
--- /dev/null
+++ b/res/drawable-hdpi/ic_switch_video_holo_dark.png
Binary files differ
diff --git a/res/drawable-mdpi/ic_menu_cancel_holo_light.png b/res/drawable-mdpi/ic_menu_cancel_holo_light.png
new file mode 100644
index 0000000..cb9abb9
--- /dev/null
+++ b/res/drawable-mdpi/ic_menu_cancel_holo_light.png
Binary files differ
diff --git a/res/drawable-mdpi/ic_menu_divider.png b/res/drawable-mdpi/ic_menu_divider.png
new file mode 100644
index 0000000..d6ded3d
--- /dev/null
+++ b/res/drawable-mdpi/ic_menu_divider.png
Binary files differ
diff --git a/res/drawable-mdpi/ic_menu_done_holo_light.png b/res/drawable-mdpi/ic_menu_done_holo_light.png
new file mode 100644
index 0000000..fb56f3a
--- /dev/null
+++ b/res/drawable-mdpi/ic_menu_done_holo_light.png
Binary files differ
diff --git a/res/drawable-mdpi/ic_switch_camera_holo_dark.png b/res/drawable-mdpi/ic_switch_camera_holo_dark.png
new file mode 100644
index 0000000..f417d34
--- /dev/null
+++ b/res/drawable-mdpi/ic_switch_camera_holo_dark.png
Binary files differ
diff --git a/res/drawable-mdpi/ic_switch_video_holo_dark.png b/res/drawable-mdpi/ic_switch_video_holo_dark.png
new file mode 100644
index 0000000..8488819
--- /dev/null
+++ b/res/drawable-mdpi/ic_switch_video_holo_dark.png
Binary files differ
diff --git a/res/drawable-xlarge-mdpi/btn_ic_review_play.png b/res/drawable-xlarge-mdpi/btn_ic_review_play.png
new file mode 100755
index 0000000..6eca85c
--- /dev/null
+++ b/res/drawable-xlarge-mdpi/btn_ic_review_play.png
Binary files differ
diff --git a/res/drawable-xlarge/btn_review_control.xml b/res/drawable-xlarge/btn_review_control.xml
new file mode 100644
index 0000000..98a44d5
--- /dev/null
+++ b/res/drawable-xlarge/btn_review_control.xml
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 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.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:state_pressed="true" android:drawable="@color/review_control_pressed_color" />
+ <item android:drawable="@android:color/transparent" />
+</selector>
+
diff --git a/res/layout-xlarge/camera_control.xml b/res/layout-xlarge/camera_control.xml
index 8d500b5..3567816 100644
--- a/res/layout-xlarge/camera_control.xml
+++ b/res/layout-xlarge/camera_control.xml
@@ -87,7 +87,6 @@
android:button="@android:color/transparent"
android:background="@drawable/btn_ic_mode_switch_camera"/>
</com.android.camera.SwitcherSet>
- <include layout="@layout/review_control"/>
<com.android.camera.ui.CameraPicker android:id="@+id/camera_picker"
android:clickable="true"
android:layout_width="wrap_content"
diff --git a/res/layout-xlarge/preview_frame.xml b/res/layout-xlarge/preview_frame.xml
index 5a62280..2872414 100644
--- a/res/layout-xlarge/preview_frame.xml
+++ b/res/layout-xlarge/preview_frame.xml
@@ -35,9 +35,9 @@
android:layout_width="match_parent"
android:layout_height="match_parent"/>
<TextView android:id="@+id/zoom_ratio"
- android:layout_alignParentTop="true"
+ style="@style/OnViewfinderLabel"
android:layout_alignParentRight="true"
- style="@style/OnViewfinderLabel"/>
+ android:layout_below="@+id/review_control"/>
<ImageView style="@style/OnScreenGpsIndicator"
android:id="@+id/onscreen_gps_indicator_no_signal"
android:src="@drawable/ic_viewfinder_gps_no_signal"
@@ -53,5 +53,6 @@
android:layout_margin="10dp"
android:visibility="invisible"/>
<include layout="@layout/review_thumbnail"/>
+ <include layout="@layout/review_control"/>
</RelativeLayout>
</com.android.camera.PreviewFrameLayout>
diff --git a/res/layout-xlarge/preview_frame_video.xml b/res/layout-xlarge/preview_frame_video.xml
index cc46a2a..7649896 100644
--- a/res/layout-xlarge/preview_frame_video.xml
+++ b/res/layout-xlarge/preview_frame_video.xml
@@ -37,24 +37,23 @@
android:visibility="gone" />
<include layout="@layout/review_thumbnail"/>
<TextView android:id="@+id/recording_time"
- style="@style/RecordingTime"
- android:layout_marginTop="20dp"
- android:layout_marginRight="26dp"
- android:layout_alignParentTop="true"
+ style="@style/OnViewfinderLabel"
+ android:layout_below="@+id/review_control"
android:layout_alignParentRight="true"
- android:paddingLeft="8dp"
- android:paddingRight="8dp"
android:gravity="center"
- android:background="@drawable/mode_switch_bg_v2"
android:drawableLeft="@drawable/ic_recording_indicator_small"
android:visibility="gone"/>
+ <include layout="@layout/review_control"/>
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
+ android:background="@color/on_viewfinder_label_background_color"
android:visibility="gone">
<ImageView style="@style/ReviewControlIcon"
android:id="@+id/btn_play"
+ android:paddingTop="10dp"
+ android:paddingBottom="10dp"
android:src="@drawable/btn_ic_review_play"/>
</LinearLayout>
<TextView android:id="@+id/time_lapse_label"
diff --git a/res/layout-xlarge/review_control.xml b/res/layout-xlarge/review_control.xml
index 9c6c5de..83b3175 100644
--- a/res/layout-xlarge/review_control.xml
+++ b/res/layout-xlarge/review_control.xml
@@ -16,39 +16,41 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/review_control"
+ style="@style/ReviewControlGroup"
android:visibility="gone"
- android:orientation="vertical"
- android:layout_height="wrap_content"
- android:layout_width="wrap_content"
- android:gravity="top|center_horizontal"
- android:layout_alignParentBottom="true"
+ android:layout_alignParentTop="true"
android:layout_alignParentRight="true"
- android:layout_marginRight="180dp">
+ android:layout_marginRight="20dp"
+ android:layout_marginTop="20dp"
+ android:background="@color/on_viewfinder_label_background_color">
+
<LinearLayout style="@style/ReviewControlGroup"
- android:visibility="gone"
- android:layout_alignParentBottom="true"
- android:layout_centerHorizontal="true">
- <ImageView style="@style/ReviewControlIcon"
- android:id="@+id/btn_done"
- android:src="@drawable/btn_ic_review_done"/>
- <TextView style="@style/ReviewControlText"
- android:text="@string/review_ok" />
+ android:visibility="gone">
+ <Button android:id="@+id/btn_done"
+ style="@style/ReviewControlIcon"
+ android:drawableLeft="@drawable/ic_menu_done_holo_light"
+ android:text="@string/review_ok"/>
+ <ImageView
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:src="@drawable/ic_menu_divider"/>
</LinearLayout>
<LinearLayout style="@style/ReviewControlGroup"
- android:visibility="gone"
- android:layout_marginBottom="15dp">
- <ImageView style="@style/ReviewControlIcon"
- android:id="@+id/btn_retake"
- android:src="@drawable/btn_ic_review_retake_photo"/>
- <TextView style="@style/ReviewControlText"
- android:text="@string/review_retake" />
+ android:visibility="gone">
+ <Button android:id="@+id/btn_retake"
+ style="@style/ReviewControlIcon"
+ android:scaleType="center"
+ android:clickable="true"
+ android:drawableLeft="@drawable/ic_switch_camera_holo_dark"/>
+ <ImageView
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:src="@drawable/ic_menu_divider"/>
</LinearLayout>
- <LinearLayout style="@style/ReviewControlGroup"
- android:layout_marginBottom="15dp">
- <ImageView style="@style/ReviewControlIcon"
- android:id="@+id/btn_cancel"
- android:src="@drawable/btn_ic_review_cancel"/>
- <TextView style="@style/ReviewControlText"
- android:text="@string/review_cancel" />
+ <LinearLayout style="@style/ReviewControlGroup">
+ <Button android:id="@+id/btn_cancel"
+ style="@style/ReviewControlIcon"
+ android:drawableLeft="@drawable/ic_menu_cancel_holo_light"
+ android:text="@string/review_cancel"/>
</LinearLayout>
</LinearLayout>
diff --git a/res/values-xlarge/styles.xml b/res/values-xlarge/styles.xml
index dd9c8f5..f75819b 100644
--- a/res/values-xlarge/styles.xml
+++ b/res/values-xlarge/styles.xml
@@ -20,4 +20,17 @@
<resources xmlns:android="http://schemas.android.com/apk/res/android">
<style name="ThemeCamera" parent="android:Theme.Holo.NoActionBar">
</style>
+ <style name="ReviewControlGroup">
+ <item name="android:orientation">horizontal</item>
+ <item name="android:layout_height">wrap_content</item>
+ <item name="android:layout_width">wrap_content</item>
+ <item name="android:gravity">center</item>
+ </style>
+ <style name="ReviewControlIcon">
+ <item name="android:layout_height">wrap_content</item>
+ <item name="android:layout_width">wrap_content</item>
+ <item name="android:paddingLeft">15dp</item>
+ <item name="android:paddingRight">15dp</item>
+ <item name="android:background">@drawable/btn_review_control</item>
+ </style>
</resources>
diff --git a/res/values/colors.xml b/res/values/colors.xml
index 1306c47..530cab7 100644
--- a/res/values/colors.xml
+++ b/res/values/colors.xml
@@ -22,4 +22,5 @@
<color name="recording_time_remaining_text">#FFFF0033</color>
<color name="zoom_picker_btn_pressed">#FFFFAD00</color>
<color name="on_viewfinder_label_background_color">#77333333</color>
+ <color name="review_control_pressed_color">#FF6899FF</color>
</resources>
diff --git a/res/values/strings.xml b/res/values/strings.xml
index 6800f29..8102bc3 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -82,16 +82,16 @@
<string name="confirm_restore_message">Camera settings will be restored to defaults.</string>
<!-- button in review mode indicating that the video just taken should be played -->
- <string name="review_play">PLAY</string>
+ <string name="review_play">Play</string>
<!-- button in review mode indicating that the video recording session should be canceled -->
- <string name="review_cancel">CANCEL</string>
+ <string name="review_cancel">Cancel</string>
<!-- button in review mode indicating that the taken video is OK to be attached/uploaded -->
- <string name="review_ok">OK</string>
+ <string name="review_ok">Ok</string>
<!-- button in review mode indicate the user want to retake another picture for attachment -->
- <string name="review_retake">RETAKE</string>
+ <string name="review_retake">Retake</string>
<!-- button indicating that the picture just taken should be deleted -->