diff options
Diffstat (limited to 'core')
-rw-r--r-- | core/java/com/android/internal/policy/PhoneWindow.java | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/core/java/com/android/internal/policy/PhoneWindow.java b/core/java/com/android/internal/policy/PhoneWindow.java index a7bdbe0..8e8d352 100644 --- a/core/java/com/android/internal/policy/PhoneWindow.java +++ b/core/java/com/android/internal/policy/PhoneWindow.java @@ -3010,16 +3010,16 @@ public class PhoneWindow extends Window implements MenuBuilder.Callback { int vis = show ? VISIBLE : INVISIBLE; visibilityChanged = state.targetVisibility != vis; state.targetVisibility = vis; + LayoutParams lp = (LayoutParams) view.getLayoutParams(); + if (lp.height != resolvedHeight || lp.width != resolvedWidth + || lp.gravity != resolvedGravity || lp.rightMargin != rightMargin) { + lp.height = resolvedHeight; + lp.width = resolvedWidth; + lp.gravity = resolvedGravity; + lp.rightMargin = rightMargin; + view.setLayoutParams(lp); + } if (show) { - LayoutParams lp = (LayoutParams) view.getLayoutParams(); - if (lp.height != resolvedHeight || lp.width != resolvedWidth - || lp.gravity != resolvedGravity || lp.rightMargin != rightMargin) { - lp.height = resolvedHeight; - lp.width = resolvedWidth; - lp.gravity = resolvedGravity; - lp.rightMargin = rightMargin; - view.setLayoutParams(lp); - } view.setBackgroundColor(color); } } |