mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-27 15:26:58 +00:00
Merge "ShareTargets animations and styling." into sc-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
1408c6459c
@@ -189,6 +189,14 @@ public class OverviewActionsView<T extends OverlayUICallbacks> extends FrameLayo
|
||||
|
||||
/** Updates vertical margins for different navigation mode or configuration changes. */
|
||||
public void updateVerticalMargin(Mode mode) {
|
||||
LayoutParams actionParams = (LayoutParams) findViewById(
|
||||
R.id.action_buttons).getLayoutParams();
|
||||
actionParams.setMargins(
|
||||
actionParams.leftMargin, actionParams.topMargin, actionParams.rightMargin,
|
||||
getBottomVerticalMargin(mode));
|
||||
}
|
||||
|
||||
protected int getBottomVerticalMargin(Mode mode) {
|
||||
int bottomMargin;
|
||||
int orientation = getResources().getConfiguration().orientation;
|
||||
if (orientation == Configuration.ORIENTATION_LANDSCAPE) {
|
||||
@@ -201,8 +209,6 @@ public class OverviewActionsView<T extends OverlayUICallbacks> extends FrameLayo
|
||||
.getDimensionPixelSize(R.dimen.overview_actions_bottom_margin_gesture);
|
||||
}
|
||||
bottomMargin += mInsets.bottom;
|
||||
LayoutParams params = (LayoutParams) getLayoutParams();
|
||||
params.setMargins(
|
||||
params.leftMargin, params.topMargin, params.rightMargin, bottomMargin);
|
||||
return bottomMargin;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user