Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8bc623a1 authored by Daniel Sandler's avatar Daniel Sandler Committed by Android Git Automerger
Browse files

am fc12f1e3: Merge "Log messages to debug stuck status bars."

# Via Android (Google) Code Review (1) and Daniel Sandler (1)
* commit 'fc12f1e3':
  Log messages to debug stuck status bars.
parents f5db9b8e fc12f1e3
Loading
Loading
Loading
Loading
+12 −2
Original line number Diff line number Diff line
@@ -96,14 +96,21 @@ public class PanelBar extends FrameLayout {
    @Override
    public boolean onTouchEvent(MotionEvent event) {
        // Allow subclasses to implement enable/disable semantics
        if (!panelsEnabled()) return false;
        if (!panelsEnabled()) {
            if (event.getAction() == MotionEvent.ACTION_DOWN) {
                Slog.v(TAG, String.format("onTouch: all panels disabled, ignoring touch at (%d,%d)",
                        (int) event.getX(), (int) event.getY()));
            }
            return false;
        }

        // figure out which panel needs to be talked to here
        if (event.getAction() == MotionEvent.ACTION_DOWN) {
            final PanelView panel = selectPanelForTouch(event);
            if (panel == null) {
                // panel is not there, so we'll eat the gesture
                if (DEBUG) LOG("PanelBar.onTouch: no panel for x=%d, bailing", event.getX());
                Slog.v(TAG, String.format("onTouch: no panel for touch at (%d,%d)",
                        (int) event.getX(), (int) event.getY()));
                mTouchingPanel = null;
                return true;
            }
@@ -112,6 +119,9 @@ public class PanelBar extends FrameLayout {
                    (enabled ? "" : " (disabled)"));
            if (!enabled) {
                // panel is disabled, so we'll eat the gesture
                Slog.v(TAG, String.format(
                        "onTouch: panel (%s) is disabled, ignoring touch at (%d,%d)",
                        panel, (int) event.getX(), (int) event.getY()));
                mTouchingPanel = null;
                return true;
            }