diff options
author | Joe Onorato <joeo@android.com> | 2010-10-11 16:24:50 -0700 |
---|---|---|
committer | Joe Onorato <joeo@android.com> | 2010-10-11 16:24:50 -0700 |
commit | 0d7349bd92b2dc6c304f6a380a81d4c546ec21c0 (patch) | |
tree | cfa03fec666bcb783bb1c068fdbcc24d275397ca /packages | |
parent | c0ad216c8ebc74b59074a7538533605eebfd65c3 (diff) | |
download | frameworks_base-0d7349bd92b2dc6c304f6a380a81d4c546ec21c0.zip frameworks_base-0d7349bd92b2dc6c304f6a380a81d4c546ec21c0.tar.gz frameworks_base-0d7349bd92b2dc6c304f6a380a81d4c546ec21c0.tar.bz2 |
Fix status bar flashing after orientation change
hand merge 43a87c5c874f1b8fbf582ff522f10051a6434906
and add some more fixes
Change-Id: Iea608bfba37e2e4c6a3430c13f683e54b0eff64b
Diffstat (limited to 'packages')
-rw-r--r-- | packages/SystemUI/src/com/android/systemui/statusbar/StatusBarService.java | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/StatusBarService.java b/packages/SystemUI/src/com/android/systemui/statusbar/StatusBarService.java index f3da2a3..8f3e0fe 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/StatusBarService.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/StatusBarService.java @@ -294,6 +294,7 @@ public class StatusBarService extends Service implements CommandQueue.Callbacks mScrollView = (ScrollView)expanded.findViewById(R.id.scroll); mNotificationLinearLayout = expanded.findViewById(R.id.notificationLinearLayout); + mExpandedView.setVisibility(View.GONE); mOngoingTitle.setVisibility(View.GONE); mLatestTitle.setVisibility(View.GONE); @@ -691,6 +692,7 @@ public class StatusBarService extends Service implements CommandQueue.Callbacks mExpandedDialog.getWindow().setAttributes(mExpandedParams); mExpandedView.requestFocus(View.FOCUS_FORWARD); mTrackingView.setVisibility(View.VISIBLE); + mExpandedView.setVisibility(View.VISIBLE); if (!mTicking) { setDateViewVisibility(true, com.android.internal.R.anim.fade_in); @@ -767,6 +769,7 @@ public class StatusBarService extends Service implements CommandQueue.Callbacks mExpandedParams.flags &= ~WindowManager.LayoutParams.FLAG_ALT_FOCUSABLE_IM; mExpandedDialog.getWindow().setAttributes(mExpandedParams); mTrackingView.setVisibility(View.GONE); + mExpandedView.setVisibility(View.GONE); if ((mDisabled & StatusBarManager.DISABLE_NOTIFICATION_ICONS) == 0) { setNotificationIconVisibility(true, com.android.internal.R.anim.fade_in); @@ -1323,29 +1326,26 @@ public class StatusBarService extends Service implements CommandQueue.Callbacks mExpandedContents.getLocationInWindow(mPositionTmp); final int contentsBottom = mPositionTmp[1] + mExpandedContents.getHeight(); - mExpandedParams.y = pos + mTrackingView.getHeight() - - (mTrackingParams.height-closePos) - contentsBottom; - int max = h; - if (mExpandedParams.y > max) { - mExpandedParams.y = max; - } - int min = mTrackingPosition; - if (mExpandedParams.y < min) { - mExpandedParams.y = min; - } + if (expandedPosition != EXPANDED_LEAVE_ALONE) { + mExpandedParams.y = pos + mTrackingView.getHeight() + - (mTrackingParams.height-closePos) - contentsBottom; + int max = h; + if (mExpandedParams.y > max) { + mExpandedParams.y = max; + } + int min = mTrackingPosition; + if (mExpandedParams.y < min) { + mExpandedParams.y = min; + } - boolean visible = (mTrackingPosition + mTrackingView.getHeight()) > h; - if (!visible) { - // if the contents aren't visible, move the expanded view way off screen - // because the window itself extends below the content view. - mExpandedParams.y = -disph; - } - mExpandedDialog.getWindow().setAttributes(mExpandedParams); + boolean visible = (mTrackingPosition + mTrackingView.getHeight()) > h; + if (!visible) { + // if the contents aren't visible, move the expanded view way off screen + // because the window itself extends below the content view. + mExpandedParams.y = -disph; + } + mExpandedDialog.getWindow().setAttributes(mExpandedParams); - // As long as this isn't just a repositioning that's not supposed to affect - // the user's perception of what's showing, call to say that the visibility - // has changed. (Otherwise, someone else will call to do that). - if (expandedPosition != EXPANDED_LEAVE_ALONE) { if (SPEW) Slog.d(TAG, "updateExpandedViewPos visibilityChanged(" + visible + ")"); visibilityChanged(visible); } |