1<?xml version="1.0" encoding="utf-8"?> 2<!-- Copyright (C) 2011 The Android Open Source Project 3 4 Licensed under the Apache License, Version 2.0 (the "License"); 5 you may not use this file except in compliance with the License. 6 You may obtain a copy of the License at 7 8 http://www.apache.org/licenses/LICENSE-2.0 9 10 Unless required by applicable law or agreed to in writing, software 11 distributed under the License is distributed on an "AS IS" BASIS, 12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 See the License for the specific language governing permissions and 14 limitations under the License. 15--> 16<com.android.camera.ModePicker xmlns:android="http://schemas.android.com/apk/res/android" 17 android:id="@+id/mode_picker" 18 android:layout_height="match_parent" 19 android:layout_width="wrap_content" 20 android:layout_alignParentLeft="true" 21 android:visibility="gone"> 22 <!-- minHeight in camera_control.xml is used to avoid overlapping of current_mode. --> 23 <RelativeLayout android:id="@+id/current_mode" 24 android:layout_alignLeft="@+id/mode_selection" 25 android:layout_height="match_parent" 26 android:layout_width="55dp" 27 android:contentDescription="@string/accessibility_mode_picker" 28 android:background="@drawable/bg_mode_picker"> 29 <RelativeLayout 30 android:contentDescription="@string/empty" 31 android:layout_height="match_parent" 32 android:layout_width="match_parent"> 33 <com.android.camera.ui.RotateImageView android:id="@+id/mode_0" 34 android:layout_height="32dp" 35 android:layout_width="32dp" 36 android:layout_centerHorizontal="true" 37 android:layout_alignParentTop="true" 38 android:layout_marginTop="8dp" 39 android:scaleType="fitCenter" 40 android:contentDescription="@string/empty" 41 android:src="@drawable/ic_switch_video_holo_light" /> 42 <com.android.camera.ui.RotateImageView android:id="@+id/mode_1" 43 android:layout_height="wrap_content" 44 android:layout_width="wrap_content" 45 android:layout_centerInParent="true" 46 android:scaleType="fitCenter" 47 android:contentDescription="@string/empty" 48 android:src="@drawable/ic_switch_camera_holo_light" /> 49 <com.android.camera.ui.RotateImageView android:id="@+id/mode_2" 50 android:layout_height="32dp" 51 android:layout_width="32dp" 52 android:layout_centerHorizontal="true" 53 android:layout_alignParentBottom="true" 54 android:layout_marginBottom="8dp" 55 android:scaleType="fitCenter" 56 android:contentDescription="@string/empty" 57 android:src="@drawable/ic_switch_pan_holo_light" /> 58 </RelativeLayout> 59 <View android:layout_height="match_parent" 60 android:layout_width="1dp" 61 android:layout_alignParentRight="true" 62 android:background="@android:color/white"/> 63 </RelativeLayout> 64 <RelativeLayout android:id="@+id/mode_selection" 65 android:orientation="horizontal" 66 android:layout_height="match_parent" 67 android:layout_width="198dp" 68 android:background="@drawable/bg_switcher" 69 android:visibility="gone"> 70 <LinearLayout 71 android:orientation="horizontal" 72 android:layout_height="match_parent" 73 android:layout_width="wrap_content" 74 android:layout_centerHorizontal="true"> 75 <com.android.camera.ui.RotateImageView android:id="@+id/mode_camera" 76 android:contentDescription="@string/switch_to_camera_label" 77 android:layout_height="match_parent" 78 android:layout_width="wrap_content" 79 android:layout_marginRight="10dp" 80 android:scaleType="center" 81 android:background="@drawable/bg_pressed" 82 android:src="@drawable/ic_switch_camera_holo_light" /> 83 <com.android.camera.ui.RotateImageView android:id="@+id/mode_video" 84 android:contentDescription="@string/switch_to_video_label" 85 android:layout_height="match_parent" 86 android:layout_width="wrap_content" 87 android:layout_marginRight="10dp" 88 android:scaleType="center" 89 android:background="@drawable/bg_pressed" 90 android:src="@drawable/ic_switch_video_holo_light" /> 91 <com.android.camera.ui.RotateImageView android:id="@+id/mode_panorama" 92 android:contentDescription="@string/switch_to_panorama_label" 93 android:layout_height="match_parent" 94 android:layout_width="wrap_content" 95 android:scaleType="center" 96 android:background="@drawable/bg_pressed" 97 android:src="@drawable/ic_switch_pan_holo_light" /> 98 </LinearLayout> 99 <View android:layout_height="match_parent" 100 android:layout_width="1dp" 101 android:layout_alignParentRight="true" 102 android:background="@color/mode_selection_border"/> 103 </RelativeLayout> 104</com.android.camera.ModePicker> 105