summaryrefslogtreecommitdiffstats
path: root/res
diff options
context:
space:
mode:
authorChung-yih Wang <cywang@google.com>2011-09-19 09:11:35 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2011-09-19 09:11:35 -0700
commit13d59ec3af4d6fb4692b9d48a29ca65494fa30b0 (patch)
treeaf3fcfef23a68eeccf592319155060852d80f793 /res
parentb296c140095abe3f0c3044443a7b65badc83140d (diff)
parent6e48f6c9ef082b2beb0145ebc28189c3d1a4f072 (diff)
downloadLegacyCamera-13d59ec3af4d6fb4692b9d48a29ca65494fa30b0.zip
LegacyCamera-13d59ec3af4d6fb4692b9d48a29ca65494fa30b0.tar.gz
LegacyCamera-13d59ec3af4d6fb4692b9d48a29ca65494fa30b0.tar.bz2
am 6e48f6c9: Merge "Fix indicator bar height in video mode." into ics-factoryrom
* commit '6e48f6c9ef082b2beb0145ebc28189c3d1a4f072': Fix indicator bar height in video mode.
Diffstat (limited to 'res')
-rw-r--r--res/drawable/border_preview.xml21
-rw-r--r--res/layout-w1024dp/preview_frame.xml10
-rw-r--r--res/layout-w1024dp/preview_frame_video.xml19
-rw-r--r--res/layout/preview_frame.xml15
-rw-r--r--res/layout/preview_frame_video.xml42
5 files changed, 62 insertions, 45 deletions
diff --git a/res/drawable/border_preview.xml b/res/drawable/border_preview.xml
new file mode 100644
index 0000000..8cac1fc
--- /dev/null
+++ b/res/drawable/border_preview.xml
@@ -0,0 +1,21 @@
+<?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.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:state_activated="true" android:drawable="@drawable/ic_snapshot_border" />
+ <item android:drawable="@android:color/transparent" />
+</selector>
+
diff --git a/res/layout-w1024dp/preview_frame.xml b/res/layout-w1024dp/preview_frame.xml
index 762fef5..961a407 100644
--- a/res/layout-w1024dp/preview_frame.xml
+++ b/res/layout-w1024dp/preview_frame.xml
@@ -13,13 +13,13 @@
See the License for the specific language governing permissions and
limitations under the License.
-->
-
-<com.android.camera.PreviewFrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/frame_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1">
- <RelativeLayout android:id="@+id/frame"
+ <com.android.camera.PreviewFrameLayout android:id="@+id/frame"
+ android:layout_centerInParent="true"
android:layout_width="match_parent"
android:layout_height="match_parent">
<SurfaceView android:id="@+id/camera_preview"
@@ -32,5 +32,5 @@
<include layout="@layout/focus_indicator"/>
<include layout="@layout/priority_indicators"/>
<include layout="@layout/tap_to_focus_toast"/>
- </RelativeLayout>
-</com.android.camera.PreviewFrameLayout>
+ </com.android.camera.PreviewFrameLayout>
+</RelativeLayout>
diff --git a/res/layout-w1024dp/preview_frame_video.xml b/res/layout-w1024dp/preview_frame_video.xml
index 8a5ecd5..8099d89 100644
--- a/res/layout-w1024dp/preview_frame_video.xml
+++ b/res/layout-w1024dp/preview_frame_video.xml
@@ -14,14 +14,16 @@
limitations under the License.
-->
-<com.android.camera.PreviewFrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/frame_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1">
- <RelativeLayout android:id="@+id/frame"
+ <com.android.camera.PreviewFrameLayout android:id="@+id/frame"
android:layout_width="match_parent"
- android:layout_height="match_parent">
+ android:layout_height="match_parent"
+ android:layout_centerInParent="true"
+ android:background="@drawable/border_preview">
<SurfaceView android:id="@+id/camera_preview"
android:layout_width="match_parent"
android:layout_height="match_parent" />
@@ -59,11 +61,6 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone"
- android:background="@android:color/black" />
- </RelativeLayout>
- <!-- Border for video snapshot. -->
- <View android:id="@+id/preview_border"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:visibility="gone" />
-</com.android.camera.PreviewFrameLayout>
+ android:background="@android:color/black"/>
+ </com.android.camera.PreviewFrameLayout>
+</RelativeLayout>
diff --git a/res/layout/preview_frame.xml b/res/layout/preview_frame.xml
index a8b4d99..c225a58 100644
--- a/res/layout/preview_frame.xml
+++ b/res/layout/preview_frame.xml
@@ -14,13 +14,13 @@
limitations under the License.
-->
-<com.android.camera.PreviewFrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/frame_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
- android:layout_weight="1"
- android:layout_marginLeft="2dp">
- <RelativeLayout android:id="@+id/frame"
+ android:layout_weight="1">
+ <com.android.camera.PreviewFrameLayout android:id="@+id/frame"
+ android:layout_centerInParent="true"
android:layout_width="match_parent"
android:layout_height="match_parent">
<SurfaceView android:id="@+id/camera_preview"
@@ -33,6 +33,7 @@
<include layout="@layout/focus_indicator"/>
<include layout="@layout/priority_indicators"/>
<include layout="@layout/tap_to_focus_toast"/>
- <include layout="@layout/indicator_bar" />
- </RelativeLayout>
-</com.android.camera.PreviewFrameLayout>
+ </com.android.camera.PreviewFrameLayout>
+ <include layout="@layout/indicator_bar" />
+</RelativeLayout>
+
diff --git a/res/layout/preview_frame_video.xml b/res/layout/preview_frame_video.xml
index a922c6a..e07de71 100644
--- a/res/layout/preview_frame_video.xml
+++ b/res/layout/preview_frame_video.xml
@@ -14,15 +14,16 @@
limitations under the License.
-->
-<com.android.camera.PreviewFrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/frame_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
- android:layout_weight="1"
- android:layout_marginLeft="2dip">
- <RelativeLayout android:id="@+id/frame"
+ android:layout_weight="1">
+ <com.android.camera.PreviewFrameLayout android:id="@+id/frame"
android:layout_width="match_parent"
- android:layout_height="match_parent">
+ android:layout_height="match_parent"
+ android:layout_centerInParent="true"
+ android:background="@drawable/border_preview">
<SurfaceView android:id="@+id/camera_preview"
android:layout_width="match_parent"
android:layout_height="match_parent"/>
@@ -49,21 +50,18 @@
android:layout_height="match_parent"
android:visibility="gone"
android:background="@android:color/black"/>
- <include layout="@layout/indicator_bar"/>
<TextView android:id="@+id/bg_replace_message"
- android:layout_width="300dp"
- android:layout_height="wrap_content"
- android:layout_centerInParent="true"
- android:padding="32dp"
- android:layout_margin="24dp"
- android:textAppearance="?android:attr/textAppearanceMedium"
- android:background="@drawable/bg_text_on_preview"
- android:visibility="gone"
- android:text="@string/bg_replacement_message" />
- </RelativeLayout>
- <!-- Border for video snapshot. -->
- <View android:id="@+id/preview_border"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:visibility="gone"/>
-</com.android.camera.PreviewFrameLayout>
+ android:layout_width="300dp"
+ android:layout_height="wrap_content"
+ android:layout_centerInParent="true"
+ android:padding="32dp"
+ android:layout_margin="24dp"
+ android:textAppearance="?android:attr/textAppearanceMedium"
+ android:background="@drawable/bg_text_on_preview"
+ android:visibility="gone"
+ android:text="@string/bg_replacement_message" />
+ </com.android.camera.PreviewFrameLayout>
+ <!-- Indicator control and popup window frame. -->
+ <include layout="@layout/indicator_bar" />
+</RelativeLayout>
+