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

Commit 5d2ee7dc authored by Hall Liu's avatar Hall Liu Committed by android-build-merger
Browse files

Merge "Add pending messages to dumpsys" am: 803e3cd3 am: e1370400

am: b743377c

Change-Id: I69ed18f4b3257b0ed23e2a07d41393fe753debaa
parents 86154825 b743377c
Loading
Loading
Loading
Loading
+10 −0
Original line number Diff line number Diff line
@@ -481,6 +481,16 @@ public class CallAudioManager extends CallsManagerListenerBase {

        pw.println("Foreground call:");
        pw.println(mForegroundCall);

        pw.println("CallAudioModeStateMachine pending messages:");
        pw.increaseIndent();
        mCallAudioModeStateMachine.dumpPendingMessages(pw);
        pw.decreaseIndent();

        pw.println("CallAudioRouteStateMachine pending messages:");
        pw.increaseIndent();
        mCallAudioRouteStateMachine.dumpPendingMessages(pw);
        pw.decreaseIndent();
    }

    @VisibleForTesting
+5 −0
Original line number Diff line number Diff line
@@ -24,6 +24,7 @@ import android.telecom.Logging.Session;
import android.util.SparseArray;

import com.android.internal.util.IState;
import com.android.internal.util.IndentingPrintWriter;
import com.android.internal.util.State;
import com.android.internal.util.StateMachine;

@@ -515,6 +516,10 @@ public class CallAudioModeStateMachine extends StateMachine {
        }
    }

    public void dumpPendingMessages(IndentingPrintWriter pw) {
        getHandler().getLooper().dump(pw::println, "");
    }

    @Override
    protected void onPostHandleMessage(Message msg) {
        Log.endSession();
+5 −0
Original line number Diff line number Diff line
@@ -37,6 +37,7 @@ import android.telecom.Logging.Session;
import android.util.SparseArray;

import com.android.internal.util.IState;
import com.android.internal.util.IndentingPrintWriter;
import com.android.internal.util.State;
import com.android.internal.util.StateMachine;
import com.android.server.telecom.bluetooth.BluetoothRouteManager;
@@ -1318,6 +1319,10 @@ public class CallAudioRouteStateMachine extends StateMachine {
        quitNow();
    }

    public void dumpPendingMessages(IndentingPrintWriter pw) {
        getHandler().getLooper().dump(pw::println, "");
    }

    /**
     * Sets whether notifications should be suppressed or not.  Used when in a call to ensure the
     * device will not vibrate due to notifications.