Merge "Disable debug logging" into tm-dev

This commit is contained in:
TreeHugger Robot
2022-05-25 22:52:28 +00:00
committed by Android (Google) Code Review
2 changed files with 1 additions and 7 deletions

View File

@@ -20,7 +20,6 @@ import android.annotation.IntDef;
import android.annotation.IntRange;
import android.annotation.NonNull;
import android.annotation.SuppressLint;
import android.os.Build;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
@@ -38,7 +37,7 @@ public interface OnBackInvokedDispatcher {
String TAG = "OnBackInvokedDispatcher";
/** @hide */
boolean DEBUG = Build.isDebuggable();
boolean DEBUG = false;
/** @hide */
@IntDef({

View File

@@ -19,7 +19,6 @@ package android.window;
import android.annotation.NonNull;
import android.annotation.Nullable;
import android.content.Context;
import android.os.Debug;
import android.os.Handler;
import android.os.RemoteException;
import android.os.SystemProperties;
@@ -186,10 +185,6 @@ public class WindowOnBackInvokedDispatcher implements OnBackInvokedDispatcher {
callbackInfo = new OnBackInvokedCallbackInfo(iCallback, priority);
}
mWindowSession.setOnBackInvokedCallbackInfo(mWindow, callbackInfo);
if (DEBUG && callback == null) {
Log.d(TAG, TextUtils.formatSimple("setTopOnBackInvokedCallback(null) Callers:%s",
Debug.getCallers(5, " ")));
}
} catch (RemoteException e) {
Log.e(TAG, "Failed to set OnBackInvokedCallback to WM. Error: " + e);
}