Adding verbose check on handleSendEvent logs to avoid spamming logcat

Test: N/A
Bug: 190239442
Bug: 191684350
Change-Id: I6059b1daa3fa0447d6ed6640490fc9129b4fc932
This commit is contained in:
Alex Mang
2021-06-24 17:03:29 -07:00
parent e3ece36d51
commit 5a32c88649

View File

@@ -323,9 +323,11 @@ public final class MainContentCaptureSession extends ContentCaptureSession {
if (!hasStarted() && eventType != ContentCaptureEvent.TYPE_SESSION_STARTED
&& eventType != ContentCaptureEvent.TYPE_CONTEXT_UPDATED) {
// TODO(b/120494182): comment when this could happen (dialogs?)
Log.v(TAG, "handleSendEvent(" + getDebugState() + ", "
+ ContentCaptureEvent.getTypeAsString(eventType)
+ "): dropping because session not started yet");
if (sVerbose) {
Log.v(TAG, "handleSendEvent(" + getDebugState() + ", "
+ ContentCaptureEvent.getTypeAsString(eventType)
+ "): dropping because session not started yet");
}
return;
}
if (mDisabled.get()) {