Home | History | Annotate | Download | only in layout
      1 <?xml version="1.0" encoding="utf-8"?>
      2 <!-- Copyright (C) 2013 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 
     17 <!-- This layout is shared by phone and tablet in both landscape and portrait
     18  orientation. The purpose of having this layout is to eventually not manually
     19  recreate views when the orientation changes, by migrating the views that do not
     20  need to be recreated in onConfigurationChanged from old photo_module to this
     21  layout. -->
     22 
     23 <merge xmlns:android="http://schemas.android.com/apk/res/android"
     24     android:layout_width="match_parent"
     25     android:layout_height="match_parent"
     26     android:layout_gravity="center">
     27     <!-- Wrap a frame layout around texture view so that when scaled, texture
     28          view will not draw outside its unscaled bounds -->
     29     <FrameLayout
     30         android:layout_width="match_parent"
     31         android:layout_height="match_parent">
     32         <TextureView
     33             android:id="@+id/preview_content"
     34             android:layout_width="match_parent"
     35             android:layout_height="match_parent" />
     36         <View
     37             android:id="@+id/preview_cover"
     38             android:layout_width="match_parent"
     39             android:layout_height="match_parent"
     40             android:background="@android:color/black"
     41             android:visibility="gone" />
     42     </FrameLayout>
     43     <ImageView
     44         android:id="@+id/review_image"
     45         android:layout_width="match_parent"
     46         android:layout_height="match_parent"
     47         android:visibility="gone"
     48         android:clickable="true"
     49         android:background="@android:color/black"
     50         android:scaleType="fitCenter"/>
     51     <View
     52         android:id="@+id/flash_overlay"
     53         android:layout_width="match_parent"
     54         android:layout_height="match_parent"
     55         android:background="@android:color/white"
     56         android:visibility="gone"
     57         android:alpha="0" />
     58     <ViewStub android:id="@+id/face_view_stub"
     59         android:inflatedId="@+id/face_view"
     60         android:layout="@layout/face_view"
     61         android:layout_width="match_parent"
     62         android:layout_height="match_parent"
     63         android:visibility="gone"/>
     64     <com.android.camera.ui.RenderOverlay
     65         android:id="@+id/render_overlay"
     66         android:layout_width="match_parent"
     67         android:layout_height="match_parent" />
     68     <include layout="@layout/camera_controls"
     69         android:layout_gravity="center"
     70         style="@style/CameraControls"/>
     71 </merge>
     72