diff options
author | likaid <likaid@codeaurora.org> | 2015-04-10 12:41:04 +0800 |
---|---|---|
committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2015-04-09 21:42:32 -0700 |
commit | 0b798a1fe953f180645435cb56cdc15cbd036149 (patch) | |
tree | 84e5706423408975ea3bff185f74f573ba212ee5 /src/com/android/camera/VideoUI.java | |
parent | 22c2e38daad6854315c6abad634e87c3d367fa9b (diff) | |
download | android_packages_apps_Snap-0b798a1fe953f180645435cb56cdc15cbd036149.tar.gz android_packages_apps_Snap-0b798a1fe953f180645435cb56cdc15cbd036149.tar.bz2 android_packages_apps_Snap-0b798a1fe953f180645435cb56cdc15cbd036149.zip |
SnapdragonCamera: Popup menu doesn't support RTL mode
Coordinate direction is opposite in RTL mode.
Modify Coordinate direction in RTL mode.
Change-Id: I3fcd42fc27d430b486f9cccdde5ecec0d0468d30
CRs-Fixed: 819310
Diffstat (limited to 'src/com/android/camera/VideoUI.java')
-rw-r--r-- | src/com/android/camera/VideoUI.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/com/android/camera/VideoUI.java b/src/com/android/camera/VideoUI.java index cc06e7b79..8fbae5ee6 100644 --- a/src/com/android/camera/VideoUI.java +++ b/src/com/android/camera/VideoUI.java @@ -793,8 +793,11 @@ public class VideoUI implements PieRenderer.PieListener, int y = Math.max(0, yBase); if (yBase + height > screenHeight) y = Math.max(0, screenHeight - height); - layoutParams.setMargins(0, y, 0, 0); - layoutParams.setMarginStart(CameraActivity.SETTING_LIST_WIDTH_1); + if (mRootView.getLayoutDirection() != View.LAYOUT_DIRECTION_RTL) { + layoutParams.setMargins(CameraActivity.SETTING_LIST_WIDTH_1, y, 0, 0); + } else { + layoutParams.setMargins(0, y, CameraActivity.SETTING_LIST_WIDTH_1, 0); + } mSubMenuLayout.setLayoutParams(layoutParams); mSubMenuLayout.addView(popup); |