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

Commit d7e39b59 authored by Jeff DeCew's avatar Jeff DeCew Committed by Android (Google) Code Review
Browse files

Merge "Add Compile.IS_DEBUG to systemui"

parents e4136df4 c7be05d8
Loading
Loading
Loading
Loading
+23 −0
Original line number Diff line number Diff line
/*
 * Copyright (C) 2021 The Android Open Source Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package com.android.systemui.util;

/** Constants that vary by compilation configuration. */
public class Compile {
    /** Whether SystemUI was compiled in debug mode, and supports debug features */
    public static final boolean IS_DEBUG = true;
}
+23 −0
Original line number Diff line number Diff line
/*
 * Copyright (C) 2021 The Android Open Source Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package com.android.systemui.util;

/** Constants that vary by compilation configuration. */
public class Compile {
    /** Whether SystemUI was compiled in debug mode, and supports debug features */
    public static final boolean IS_DEBUG = false;
}
+2 −1
Original line number Diff line number Diff line
@@ -59,6 +59,7 @@ import com.android.systemui.statusbar.notification.collection.notifcollection.No
import com.android.systemui.statusbar.notification.dagger.NotificationsModule;
import com.android.systemui.statusbar.notification.logging.NotificationLogger;
import com.android.systemui.util.Assert;
import com.android.systemui.util.Compile;
import com.android.systemui.util.leak.LeakDetector;

import java.io.FileDescriptor;
@@ -1011,7 +1012,7 @@ public class NotificationEntryManager implements
    }

    private static final String TAG = "NotificationEntryMgr";
    private static final boolean DEBUG = Log.isLoggable(TAG, Log.DEBUG);
    private static final boolean DEBUG = Compile.IS_DEBUG && Log.isLoggable(TAG, Log.DEBUG);

    /**
     * Used when a notification is removed and it doesn't have a reason that maps to one of the
+3 −3
Original line number Diff line number Diff line
@@ -34,9 +34,9 @@ import com.android.systemui.statusbar.notification.collection.NotificationEntry;
import com.android.systemui.statusbar.notification.collection.render.GroupExpansionManager;
import com.android.systemui.statusbar.notification.collection.render.GroupMembershipManager;
import com.android.systemui.statusbar.notification.people.PeopleNotificationIdentifier;
import com.android.systemui.statusbar.phone.StatusBar;
import com.android.systemui.statusbar.policy.HeadsUpManager;
import com.android.systemui.statusbar.policy.OnHeadsUpChangedListener;
import com.android.systemui.util.Compile;
import com.android.wm.shell.bubbles.Bubbles;

import java.io.FileDescriptor;
@@ -69,8 +69,8 @@ public class NotificationGroupManagerLegacy implements
        Dumpable {

    private static final String TAG = "NotifGroupManager";
    private static final boolean DEBUG = StatusBar.DEBUG;
    private static final boolean SPEW = StatusBar.SPEW;
    private static final boolean DEBUG = Compile.IS_DEBUG && Log.isLoggable(TAG, Log.DEBUG);
    private static final boolean SPEW = Compile.IS_DEBUG && Log.isLoggable(TAG, Log.VERBOSE);
    /**
     * The maximum amount of time (in ms) between the posting of notifications that can be
     * considered part of the same update batch.
+3 −2
Original line number Diff line number Diff line
@@ -40,6 +40,7 @@ import com.android.systemui.statusbar.notification.NotificationFilter;
import com.android.systemui.statusbar.notification.collection.NotificationEntry;
import com.android.systemui.statusbar.policy.BatteryController;
import com.android.systemui.statusbar.policy.HeadsUpManager;
import com.android.systemui.util.Compile;

import java.util.ArrayList;
import java.util.List;
@@ -52,8 +53,8 @@ import javax.inject.Inject;
@SysUISingleton
public class NotificationInterruptStateProviderImpl implements NotificationInterruptStateProvider {
    private static final String TAG = "InterruptionStateProvider";
    private static final boolean DEBUG = true; //false;
    private static final boolean DEBUG_HEADS_UP = true;
    private static final boolean DEBUG = Compile.IS_DEBUG;
    private static final boolean DEBUG_HEADS_UP = Compile.IS_DEBUG;
    private static final boolean ENABLE_HEADS_UP = true;
    private static final String SETTING_HEADS_UP_TICKER = "ticker_gets_heads_up";

Loading