diff options
author | Likai Ding <likaid@codeaurora.org> | 2014-12-18 23:25:22 +0800 |
---|---|---|
committer | Likai Ding <likaid@codeaurora.org> | 2015-01-08 17:58:23 +0800 |
commit | 37c3c7cc832adbd8b78fa0a3e1f8d074111638d9 (patch) | |
tree | 3600024572e813303d01bdcec417ed271762cb76 /res | |
parent | cc56779da62644898eb319d4b296f69d6d820013 (diff) | |
download | android_packages_apps_Snap-37c3c7cc832adbd8b78fa0a3e1f8d074111638d9.tar.gz android_packages_apps_Snap-37c3c7cc832adbd8b78fa0a3e1f8d074111638d9.tar.bz2 android_packages_apps_Snap-37c3c7cc832adbd8b78fa0a3e1f8d074111638d9.zip |
SnapdragonCamera: support 4:3 preview on 16:9 screen
When preview is set to 4:3 on a 16:9 screen, resize SurfaceView to 4:3
and cover other parts of the screen. Otherwise camera controls have
a semi-transparent background.
Change-Id: Icfbe6318b6a9de9a988468078b474e842f6ddd8c
Diffstat (limited to 'res')
-rw-r--r-- | res/layout/photo_module.xml | 4 | ||||
-rw-r--r-- | res/values/colors.xml | 3 | ||||
-rw-r--r-- | res/values/dimens.xml | 4 |
3 files changed, 11 insertions, 0 deletions
diff --git a/res/layout/photo_module.xml b/res/layout/photo_module.xml index 5047112a0..9407e1af9 100644 --- a/res/layout/photo_module.xml +++ b/res/layout/photo_module.xml @@ -124,12 +124,16 @@ android:background="@android:color/white" android:visibility="gone" android:alpha="0" /> + <FrameLayout + android:layout_width="match_parent" + android:layout_height="match_parent"> <ViewStub android:id="@+id/face_view_stub" android:inflatedId="@+id/face_view" android:layout="@layout/face_view" android:layout_width="match_parent" android:layout_height="match_parent" android:visibility="gone"/> + </FrameLayout> <com.android.camera.ui.RenderOverlay android:id="@+id/render_overlay" android:layout_width="match_parent" diff --git a/res/values/colors.xml b/res/values/colors.xml index cd7f5977d..dba33f40d 100644 --- a/res/values/colors.xml +++ b/res/values/colors.xml @@ -73,4 +73,7 @@ <color name="setting_color">#ff10aadc</color> <color name="setting_color_light">#ffade9fd</color> <color name="list_divider_color">#d8ababab</color> + + <color name="camera_control_bg_opaque">#ff191919</color> + <color name="camera_control_bg_transparent">#4d191919</color> </resources> diff --git a/res/values/dimens.xml b/res/values/dimens.xml index dac42d22e..d162adf17 100644 --- a/res/values/dimens.xml +++ b/res/values/dimens.xml @@ -166,4 +166,8 @@ <dimen name="filter_mode_padding">10dp</dimen> <dimen name="remaining_photos_margin">67dp</dimen> + + <!-- Margins for 4:3 preview on 16:9 screen with 640dp height --> + <dimen name="preview_top_margin">57dp</dimen> + <dimen name="preview_bottom_margin">103dp</dimen> </resources> |