summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Jason Monk <jmonk@google.com> 2016-05-25 12:30:51 -0400
committer Jason Monk <jmonk@google.com> 2016-05-25 12:30:51 -0400
commitd075b21a85d0806ce37f75943c32799bea2befe3 (patch)
tree07bdb42f044ed0a6fffeb120cf37d2df19c8e89a
parent5c9444216d187ec2126fdd200e499a1fb3f6ee62 (diff)
QS: Fix QS touch breaking
Seems not all of the QS container logic was inside the inflate callback. Change-Id: I78a8b40d1c181f5dac7127a5b5d20d45ae0f333e Fixes: 28177371
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java44
1 files changed, 23 insertions, 21 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java
index 6a37099d0b7d..522f2502e256 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java
@@ -220,18 +220,8 @@ public class NotificationPanelView extends PanelView implements
super.onFinishInflate();
mKeyguardStatusBar = (KeyguardStatusBarView) findViewById(R.id.keyguard_header);
mKeyguardStatusView = (KeyguardStatusView) findViewById(R.id.keyguard_status_view);
- mQsAutoReinflateContainer =
- (AutoReinflateContainer) findViewById(R.id.qs_auto_reinflate_container);
- mQsAutoReinflateContainer.addInflateListener(new InflateListener() {
- @Override
- public void onInflated(View v) {
- mQsContainer = (QSContainer) v.findViewById(R.id.quick_settings_container);
- mQsContainer.setPanelView(NotificationPanelView.this);
- mQsContainer.getHeader().findViewById(R.id.expand_indicator)
- .setOnClickListener(NotificationPanelView.this);
- }
- });
mClockView = (TextView) findViewById(R.id.clock_view);
+
mNotificationContainerParent = (NotificationsQuickSettingsContainer)
findViewById(R.id.notification_container_parent);
mNotificationStackScroller = (NotificationStackScrollLayout)
@@ -239,22 +229,34 @@ public class NotificationPanelView extends PanelView implements
mNotificationStackScroller.setOnHeightChangedListener(this);
mNotificationStackScroller.setOverscrollTopChangedListener(this);
mNotificationStackScroller.setOnEmptySpaceClickListener(this);
- mNotificationStackScroller.setQsContainer(mQsContainer);
mKeyguardBottomArea = (KeyguardBottomAreaView) findViewById(R.id.keyguard_bottom_area);
mQsNavbarScrim = findViewById(R.id.qs_navbar_scrim);
mAfforanceHelper = new KeyguardAffordanceHelper(this, getContext());
mLastOrientation = getResources().getConfiguration().orientation;
- // recompute internal state when qspanel height changes
- mQsContainer.addOnLayoutChangeListener(new OnLayoutChangeListener() {
+ mQsAutoReinflateContainer =
+ (AutoReinflateContainer) findViewById(R.id.qs_auto_reinflate_container);
+ mQsAutoReinflateContainer.addInflateListener(new InflateListener() {
@Override
- public void onLayoutChange(View v, int left, int top, int right, int bottom,
- int oldLeft, int oldTop, int oldRight, int oldBottom) {
- final int height = bottom - top;
- final int oldHeight = oldBottom - oldTop;
- if (height != oldHeight) {
- onQsHeightChanged();
- }
+ public void onInflated(View v) {
+ mQsContainer = (QSContainer) v.findViewById(R.id.quick_settings_container);
+ mQsContainer.setPanelView(NotificationPanelView.this);
+ mQsContainer.getHeader().findViewById(R.id.expand_indicator)
+ .setOnClickListener(NotificationPanelView.this);
+
+ // recompute internal state when qspanel height changes
+ mQsContainer.addOnLayoutChangeListener(new OnLayoutChangeListener() {
+ @Override
+ public void onLayoutChange(View v, int left, int top, int right, int bottom,
+ int oldLeft, int oldTop, int oldRight, int oldBottom) {
+ final int height = bottom - top;
+ final int oldHeight = oldBottom - oldTop;
+ if (height != oldHeight) {
+ onQsHeightChanged();
+ }
+ }
+ });
+ mNotificationStackScroller.setQsContainer(mQsContainer);
}
});
}