Fixed a bug where the panel got into a wrong state

Bug: 17939708
Change-Id: Ieaa9dc2fc0c92ce52b02ac4ea452df47ee492ac3
This commit is contained in:
Selim Cinek
2014-10-09 17:48:05 -07:00
parent 59d9723dd7
commit 6bb4a9b356
2 changed files with 9 additions and 1 deletions

View File

@@ -774,6 +774,14 @@ public abstract class PanelView extends FrameLayout {
requestLayout();
}
public void instantCollapse() {
abortAnimations();
setExpandedFraction(0f);
if (mExpanding) {
notifyExpandingFinished();
}
}
private void abortAnimations() {
cancelPeek();
if (mHeightAnimator != null) {

View File

@@ -3733,7 +3733,7 @@ public class PhoneStatusBar extends BaseStatusBar implements DemoMode,
}
private void instantCollapseNotificationPanel() {
mNotificationPanel.setExpandedFraction(0);
mNotificationPanel.instantCollapse();
}
@Override