Skip to content

Commit

Permalink
Add session debugging function (#3238)
Browse files Browse the repository at this point in the history
  • Loading branch information
bluemarvin committed May 11, 2020
1 parent 610815d commit 9b5279a
Showing 1 changed file with 16 additions and 0 deletions.
Expand Up @@ -1687,4 +1687,20 @@ public void surfaceChanged(@NonNull final Surface surface, final int left, final
}
mState.mDisplay.surfaceChanged(surface, left, top, width, height);
}

public void logState() {
if (mState == null) {
Log.d(LOGTAG, "Session state is null");
return;
}
Log.d(LOGTAG, "Session: " + (mState.mSession != null ? mState.mSession.hashCode() : "null"));
Log.d(LOGTAG, "\tActive: " + mState.isActive());
Log.d(LOGTAG, "\tUri: " + (mState.mUri != null ? mState.mUri : "null"));
Log.d(LOGTAG, "\tFullscreen: " + mState.mFullScreen);
Log.d(LOGTAG, "\tCan go back: " + mState.mCanGoBack);
Log.d(LOGTAG, "\tCan go forward: " + mState.mCanGoForward);
if (mState.mSettings != null) {
Log.d(LOGTAG, "\tPrivate Browsing: " + mState.mSettings.isPrivateBrowsingEnabled());
}
}
}

0 comments on commit 9b5279a

Please sign in to comment.