Merge "Set the linear layout direction based on initial config" into tm-qpr-dev am: bef8a5be14 am: 9ba9bada5b
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19611365 Change-Id: Ib87bb254d8d383890f49485910eb778e113db468 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -105,6 +105,10 @@ public class DragLayout extends LinearLayout {
|
||||
MATCH_PARENT));
|
||||
((LayoutParams) mDropZoneView1.getLayoutParams()).weight = 1;
|
||||
((LayoutParams) mDropZoneView2.getLayoutParams()).weight = 1;
|
||||
int orientation = getResources().getConfiguration().orientation;
|
||||
setOrientation(orientation == Configuration.ORIENTATION_LANDSCAPE
|
||||
? LinearLayout.HORIZONTAL
|
||||
: LinearLayout.VERTICAL);
|
||||
updateContainerMargins(getResources().getConfiguration().orientation);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user