am 072039c7: Merge "Fix DISABLE_EXPAND in the tablet status bar."

* commit '072039c71e3ef0e547cec4c28f05383debf439e1':
  Fix DISABLE_EXPAND in the tablet status bar.
This commit is contained in:
Daniel Sandler
2011-08-18 07:10:35 -07:00
committed by Android Git Automerger
2 changed files with 10 additions and 14 deletions

View File

@@ -1220,9 +1220,7 @@ public class TabletStatusBar extends StatusBar implements
private View.OnClickListener mOnClickListener = new View.OnClickListener() {
public void onClick(View v) {
if (v == mNotificationTrigger) {
onClickNotificationTrigger();
} else if (v == mRecentButton) {
if (v == mRecentButton) {
onClickRecentButton();
} else if (v == mInputMethodSwitchButton) {
onClickInputMethodSwitchButton();
@@ -1232,17 +1230,6 @@ public class TabletStatusBar extends StatusBar implements
}
};
public void onClickNotificationTrigger() {
if (DEBUG) Slog.d(TAG, "clicked notification icons; disabled=" + mDisabled);
if ((mDisabled & StatusBarManager.DISABLE_EXPAND) == 0) {
int msg = !mNotificationPanel.isShowing()
? MSG_OPEN_NOTIFICATION_PANEL
: MSG_CLOSE_NOTIFICATION_PANEL;
mHandler.removeMessages(msg);
mHandler.sendEmptyMessage(msg);
}
}
public void onClickRecentButton() {
if (DEBUG) Slog.d(TAG, "clicked recent apps; disabled=" + mDisabled);
if ((mDisabled & StatusBarManager.DISABLE_EXPAND) == 0) {
@@ -1374,6 +1361,11 @@ public class TabletStatusBar extends StatusBar implements
// event.getY(),
// mInitialTouchX,
// mInitialTouchY));
if ((mDisabled & StatusBarManager.DISABLE_EXPAND) != 0) {
return true;
}
final int action = event.getAction();
switch (action) {
case MotionEvent.ACTION_DOWN:

View File

@@ -1142,6 +1142,10 @@ public class KeyguardViewMediator implements KeyguardViewCallback,
// insecure and (is covered by another window OR this feature is enabled in general)
boolean enable = !mShowing
|| ((ENABLE_STATUS_BAR_IN_KEYGUARD || mHidden) && !isSecure());
if (DEBUG) {
Log.d(TAG, "adjustStatusBarLocked: mShowing=" + mShowing + " mHidden=" + mHidden
+ " isSecure=" + isSecure() + " --> enable=" + enable);
}
mStatusBarManager.disable(enable ?
StatusBarManager.DISABLE_NONE :
( StatusBarManager.DISABLE_EXPAND