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

Commit 8d1780fd authored by Hall Liu's avatar Hall Liu Committed by Gerrit Code Review
Browse files

Merge "Add a Log.startSession in HeadsetMediaButton"

parents 783a0cf2 a148324f
Loading
Loading
Loading
Loading
+15 −10
Original line number Diff line number Diff line
@@ -45,6 +45,8 @@ public class HeadsetMediaButton extends CallsManagerListenerBase {
    private final MediaSession.Callback mSessionCallback = new MediaSession.Callback() {
        @Override
        public boolean onMediaButtonEvent(Intent intent) {
            try {
                Log.startSession("HMB.oMBE");
                KeyEvent event = (KeyEvent) intent.getParcelableExtra(Intent.EXTRA_KEY_EVENT);
                Log.v(this, "SessionCallback.onMediaButton()...  event = %s.", event);
                if ((event != null) && ((event.getKeyCode() == KeyEvent.KEYCODE_HEADSETHOOK) ||
@@ -57,6 +59,9 @@ public class HeadsetMediaButton extends CallsManagerListenerBase {
                    }
                }
                return true;
            } finally {
                Log.endSession();
            }
        }
    };