summaryrefslogtreecommitdiffstats
path: root/src/com/android/camera/ui
diff options
context:
space:
mode:
authorxianming wang <mingwax@codeaurora.org>2018-10-10 10:44:12 +0800
committerGerrit - the friendly Code Review server <code-review@localhost>2018-10-19 00:17:14 -0700
commit41a5967d677bafd0ab469ee299898b844a3e551b (patch)
treec61e81ab0c2a5f9c637b4cf408fcbbd87f11829e /src/com/android/camera/ui
parentc270e957c3aa214cb833c453a059d5a035670cfe (diff)
downloadandroid_packages_apps_Snap-41a5967d677bafd0ab469ee299898b844a3e551b.tar.gz
android_packages_apps_Snap-41a5967d677bafd0ab469ee299898b844a3e551b.tar.bz2
android_packages_apps_Snap-41a5967d677bafd0ab469ee299898b844a3e551b.zip
SnapdragonCamera: Fix UI in proMode is in disorder
No matter mWidth or mHeight value is big, choose the min value to set layoutParams. CRs-Fixed: 2322938 Change-Id: I93bf1c245e8c8aaae8d41d906a5e3ea8a73dd1b4
Diffstat (limited to 'src/com/android/camera/ui')
-rwxr-xr-xsrc/com/android/camera/ui/OneUICameraControls.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/com/android/camera/ui/OneUICameraControls.java b/src/com/android/camera/ui/OneUICameraControls.java
index 646596912..6bddf0139 100755
--- a/src/com/android/camera/ui/OneUICameraControls.java
+++ b/src/com/android/camera/ui/OneUICameraControls.java
@@ -582,7 +582,8 @@ public class OneUICameraControls extends RotatableLayout {
}
private void setProModeParameters() {
- ViewGroup.LayoutParams lp = new ViewGroup.LayoutParams(mWidth/ 4, mWidth/ 4);
+ int width = (mWidth > mHeight) ? mHeight : mWidth;
+ ViewGroup.LayoutParams lp = new ViewGroup.LayoutParams(width/ 4, width/ 4);
mExposureText.setLayoutParams(lp);
mManualText.setLayoutParams(lp);
mWhiteBalanceText.setLayoutParams(lp);