1<?xml version="1.0" encoding="utf-8"?> 2<!-- 3 Copyright (C) 2012 The Android Open Source Project 4 5 Licensed under the Apache License, Version 2.0 (the "License"); 6 you may not use this file except in compliance with the License. 7 You may obtain a copy of the License at 8 9 http://www.apache.org/licenses/LICENSE-2.0 10 11 Unless required by applicable law or agreed to in writing, software 12 distributed under the License is distributed on an "AS IS" BASIS, 13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 See the License for the specific language governing permissions and 15 limitations under the License. 16--> 17<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 18 xmlns:tools="http://schemas.android.com/tools" 19 android:layout_width="fill_parent" 20 android:layout_height="fill_parent" 21 android:orientation="horizontal" > 22 23 <LinearLayout 24 android:id="@+id/preview_column" 25 android:layout_width="0dp" 26 android:layout_height="fill_parent" 27 android:layout_weight="6" 28 android:animateLayoutChanges="false" 29 android:orientation="vertical" 30 android:visibility="visible" > 31 32 <SurfaceView 33 android:id="@+id/preview" 34 android:layout_width="fill_parent" 35 android:layout_height="0dp" 36 android:layout_weight="@integer/preview_only_weight" 37 tools:ignore="NestedWeights" /> 38 39 <SurfaceView 40 android:id="@+id/callback_view" 41 android:layout_width="fill_parent" 42 android:layout_height="0dp" 43 android:layout_weight="@integer/preview_with_callback_weight" 44 android:visibility="gone" /> 45 46 <TextView 47 android:id="@+id/log" 48 android:layout_width="fill_parent" 49 android:layout_height="10dp" 50 android:layout_weight="1" 51 android:freezesText="true" 52 android:minLines="3" 53 android:typeface="normal" /> 54 55 </LinearLayout> 56 57 <ScrollView 58 android:id="@+id/control_bar" 59 android:layout_width="0dp" 60 android:layout_height="match_parent" 61 android:layout_weight="2" 62 android:fadingEdgeLength="100dp" 63 android:requiresFadingEdge="vertical" 64 android:scrollbarAlwaysDrawVerticalTrack="true" > 65 66 <LinearLayout 67 android:id="@+id/control_bar_contents" 68 android:layout_width="match_parent" 69 android:layout_height="wrap_content" 70 android:layout_marginLeft="5dp" 71 android:orientation="vertical" > 72 73 <TextView 74 android:id="@+id/camera_spinner_label" 75 android:layout_width="wrap_content" 76 android:layout_height="wrap_content" 77 android:layout_marginTop="5dp" 78 android:layout_weight="1" 79 android:text="@string/camera_selection_prompt" 80 android:textAppearance="?android:attr/textAppearanceSmall" /> 81 82 <Spinner 83 android:id="@+id/camera_spinner" 84 android:layout_width="fill_parent" 85 android:layout_height="wrap_content" 86 android:layout_weight="1" 87 android:prompt="@string/camera_selection_prompt" /> 88 89 <CheckBox 90 android:id="@+id/keep_open_checkbox" 91 android:layout_width="wrap_content" 92 android:layout_height="wrap_content" 93 android:layout_weight="1" 94 android:text="@string/keep_open_prompt" /> 95 96 <Button 97 android:id="@+id/info_button" 98 style="?android:attr/buttonStyleSmall" 99 android:layout_width="fill_parent" 100 android:layout_height="wrap_content" 101 android:layout_gravity="center" 102 android:layout_weight="1" 103 android:text="@string/show_info" /> 104 105 <View 106 android:id="@+id/horizontal_rule_1" 107 android:layout_width="fill_parent" 108 android:layout_height="1dip" 109 android:layout_marginBottom="@dimen/horiz_rule_btm_margin" 110 android:layout_marginTop="@dimen/horiz_rule_top_margin" 111 android:background="@color/horiz_rule_color" /> 112 113 <TextView 114 android:id="@+id/preview_size_spinner_label" 115 android:layout_width="wrap_content" 116 android:layout_height="wrap_content" 117 android:layout_weight="1" 118 android:text="@string/preview_resolution_prompt" 119 android:textAppearance="?android:attr/textAppearanceSmall" /> 120 121 <Spinner 122 android:id="@+id/preview_size_spinner" 123 android:layout_width="fill_parent" 124 android:layout_height="wrap_content" 125 android:layout_weight="1" 126 android:prompt="@string/preview_resolution_prompt" /> 127 128 <TextView 129 android:id="@+id/preview_frame_rate_label" 130 android:layout_width="wrap_content" 131 android:layout_height="wrap_content" 132 android:layout_weight="1" 133 android:text="@string/preview_frame_rate_prompt" 134 android:textAppearance="?android:attr/textAppearanceSmall" /> 135 136 <Spinner 137 android:id="@+id/preview_frame_rate_spinner" 138 android:layout_width="match_parent" 139 android:layout_height="wrap_content" 140 android:layout_weight="1" /> 141 142 <ToggleButton 143 android:id="@+id/start_preview" 144 android:layout_width="fill_parent" 145 android:layout_height="wrap_content" 146 android:layout_gravity="center" 147 android:layout_weight="1" 148 android:textColorLink="@android:color/holo_blue_light" 149 android:textOff="@string/preview_off_label" 150 android:textOn="@string/preview_on_label" /> 151 152 <View 153 android:id="@+id/horizontal_rule_2" 154 android:layout_width="fill_parent" 155 android:layout_height="1dip" 156 android:layout_marginBottom="@dimen/horiz_rule_btm_margin" 157 android:layout_marginTop="@dimen/horiz_rule_top_margin" 158 android:layout_weight="1" 159 android:background="@color/horiz_rule_color" /> 160 161 <TextView 162 android:id="@+id/af_mode_spinner_label" 163 android:layout_width="wrap_content" 164 android:layout_height="wrap_content" 165 android:layout_weight="1" 166 android:text="@string/af_mode_prompt" 167 android:textAppearance="?android:attr/textAppearanceSmall" /> 168 169 <Spinner 170 android:id="@+id/af_mode_spinner" 171 android:layout_width="match_parent" 172 android:layout_height="wrap_content" 173 android:layout_weight="1" /> 174 175 <Button 176 android:id="@+id/af_button" 177 style="?android:attr/buttonStyleSmall" 178 android:layout_width="wrap_content" 179 android:layout_height="wrap_content" 180 android:layout_gravity="center" 181 android:layout_weight="1" 182 android:text="@string/trigger_autofocus" /> 183 184 <Button 185 android:id="@+id/af_cancel_button" 186 style="?android:attr/buttonStyleSmall" 187 android:layout_width="wrap_content" 188 android:layout_height="wrap_content" 189 android:layout_gravity="center" 190 android:layout_weight="1" 191 android:text="@string/cancel_autofocus" /> 192 193 <TextView 194 android:id="@+id/flash_mode_spinner_label" 195 android:layout_width="wrap_content" 196 android:layout_height="wrap_content" 197 android:layout_weight="1" 198 android:text="@string/flash_mode_label" 199 android:textAppearance="?android:attr/textAppearanceSmall" /> 200 201 <Spinner 202 android:id="@+id/flash_mode_spinner" 203 android:layout_width="match_parent" 204 android:layout_height="wrap_content" 205 android:layout_weight="1" /> 206 207 <TextView 208 android:id="@+id/exposure_label" 209 android:layout_width="wrap_content" 210 android:layout_height="wrap_content" 211 android:layout_weight="1" 212 android:text="@string/exposure_label" 213 android:textAppearance="?android:attr/textAppearanceSmall" /> 214 215 <ToggleButton 216 android:id="@+id/exposure_lock" 217 android:layout_width="fill_parent" 218 android:layout_height="wrap_content" 219 android:layout_weight="1" 220 android:textColorLink="@android:color/holo_blue_light" 221 android:textOff="@string/exposure_lock_off_label" 222 android:textOn="@string/exposure_lock_on_label" /> 223 224 <View 225 android:id="@+id/horizontal_rule_3" 226 android:layout_width="fill_parent" 227 android:layout_height="1dip" 228 android:layout_marginBottom="@dimen/horiz_rule_btm_margin" 229 android:layout_marginTop="@dimen/horiz_rule_top_margin" 230 android:layout_weight="1" 231 android:background="@color/horiz_rule_color" /> 232 233 <TextView 234 android:id="@+id/snapshot_size_spinner_label" 235 android:layout_width="wrap_content" 236 android:layout_height="wrap_content" 237 android:layout_weight="1" 238 android:text="@string/snapshot_size_prompt" 239 android:textAppearance="?android:attr/textAppearanceSmall" /> 240 241 <Spinner 242 android:id="@+id/snapshot_size_spinner" 243 android:layout_width="match_parent" 244 android:layout_height="wrap_content" 245 android:layout_weight="1" /> 246 247 <Button 248 android:id="@+id/take_picture" 249 style="?android:attr/buttonStyleSmall" 250 android:layout_width="fill_parent" 251 android:layout_height="wrap_content" 252 android:layout_weight="1" 253 android:text="@string/take_picture_label" /> 254 255 <View 256 android:id="@+id/horizontal_rule_4" 257 android:layout_width="fill_parent" 258 android:layout_height="1dip" 259 android:layout_marginBottom="@dimen/horiz_rule_btm_margin" 260 android:layout_marginTop="@dimen/horiz_rule_top_margin" 261 android:layout_weight="1" 262 android:background="@color/horiz_rule_color" /> 263 264 <TextView 265 android:id="@+id/camcorder_profile_spinner_label" 266 android:layout_width="wrap_content" 267 android:layout_height="wrap_content" 268 android:layout_weight="1" 269 android:text="@string/camcorder_profile_prompt" 270 android:textAppearance="?android:attr/textAppearanceSmall" /> 271 272 <Spinner 273 android:id="@+id/camcorder_profile_spinner" 274 android:layout_width="match_parent" 275 android:layout_height="wrap_content" 276 android:layout_weight="1" /> 277 278 <TextView 279 android:id="@+id/video_record_size_spinner_label" 280 android:layout_width="wrap_content" 281 android:layout_height="wrap_content" 282 android:layout_weight="1" 283 android:text="@string/video_record_size_prompt" 284 android:textAppearance="?android:attr/textAppearanceSmall" /> 285 286 <Spinner 287 android:id="@+id/video_record_size_spinner" 288 android:layout_width="match_parent" 289 android:layout_height="wrap_content" 290 android:layout_weight="1" /> 291 292 <TextView 293 android:id="@+id/video_frame_rate_label" 294 android:layout_width="wrap_content" 295 android:layout_height="wrap_content" 296 android:layout_weight="1" 297 android:text="@string/video_frame_rate_prompt" 298 android:textAppearance="?android:attr/textAppearanceSmall" /> 299 300 <Spinner 301 android:id="@+id/video_frame_rate_spinner" 302 android:layout_width="match_parent" 303 android:layout_height="wrap_content" 304 android:layout_weight="1" /> 305 306 <ToggleButton 307 android:id="@+id/start_record" 308 android:layout_width="fill_parent" 309 android:layout_height="wrap_content" 310 android:layout_weight="1" 311 android:textColorLink="@android:color/holo_red_dark" 312 android:textOff="@string/record_off_label" 313 android:textOn="@string/record_on_label" /> 314 315 <CheckBox 316 android:id="@+id/record_handoff_checkbox" 317 android:layout_width="wrap_content" 318 android:layout_height="wrap_content" 319 android:layout_weight="1" 320 android:text="@string/record_handoff_prompt" /> 321 322 <ToggleButton 323 android:id="@+id/record_stabilization" 324 android:layout_width="fill_parent" 325 android:layout_height="wrap_content" 326 android:layout_weight="1" 327 android:textColorLink="@android:color/holo_blue_dark" 328 android:textOff="@string/record_stabilization_off_label" 329 android:textOn="@string/record_stabilization_on_label" /> 330 331 <View 332 android:id="@+id/horizontal_rule_5" 333 android:layout_width="fill_parent" 334 android:layout_height="1dip" 335 android:layout_marginBottom="@dimen/horiz_rule_btm_margin" 336 android:layout_marginTop="@dimen/horiz_rule_top_margin" 337 android:layout_weight="1" 338 android:background="@color/horiz_rule_color" /> 339 340 <TextView 341 android:id="@+id/callback_format_spinner_label" 342 android:layout_width="wrap_content" 343 android:layout_height="wrap_content" 344 android:layout_weight="1" 345 android:text="@string/callback_format_prompt" 346 android:textAppearance="?android:attr/textAppearanceSmall" /> 347 348 <Spinner 349 android:id="@+id/callback_format_spinner" 350 android:layout_width="match_parent" 351 android:layout_height="wrap_content" 352 android:layout_weight="1" /> 353 354 <ToggleButton 355 android:id="@+id/enable_callbacks" 356 android:layout_width="wrap_content" 357 android:layout_height="wrap_content" 358 android:layout_weight="1" 359 android:textOff="@string/callbacks_off_label" 360 android:textOn="@string/callbacks_on_label" /> 361 362 </LinearLayout> 363 </ScrollView> 364 365</LinearLayout> 366