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

Commit 2fa4b2a0 authored by Vadim Tryshev's avatar Vadim Tryshev
Browse files

Using Slog everywhere.

Before, there was a mix of Logs and Slogs, and Slog should be used
in systemui to isolate its log from chatty apps.

Bug: 20024603
Change-Id: I84fc53b523698391ae605c8486b9b35b04fbcd5a
parent a260ccb3
Loading
Loading
Loading
Loading
+4 −5
Original line number Diff line number Diff line
@@ -28,7 +28,6 @@ import android.content.pm.UserInfo;
import android.os.RemoteException;
import android.os.UserHandle;
import android.os.UserManager;
import android.util.Log;
import android.util.Slog;

import com.android.internal.annotations.VisibleForTesting;
@@ -120,16 +119,16 @@ class NavigationBarAppsModel {
        try {
            ActivityInfo info = getPackageManager().getActivityInfo(component, 0, appUserId);
            if (info == null) {
                Log.e(TAG, "Activity " + component + " is not installed.");
                Slog.e(TAG, "Activity " + component + " is not installed.");
                return null;
            }

            if (!info.exported) {
                Log.e(TAG, "Activity " + component + " doesn't have 'exported' attribute.");
                Slog.e(TAG, "Activity " + component + " doesn't have 'exported' attribute.");
                return null;
            }
        } catch (RemoteException e) {
            Log.e(TAG, "Failed to get activity info for " + component, e);
            Slog.e(TAG, "Failed to get activity info for " + component, e);
            return null;
        }

@@ -150,7 +149,7 @@ class NavigationBarAppsModel {
            }
        }

        Log.e(TAG, "Activity doesn't have category Intent.CATEGORY_LAUNCHER " + component);
        Slog.e(TAG, "Activity doesn't have category Intent.CATEGORY_LAUNCHER " + component);
        return null;
    }

+3 −4
Original line number Diff line number Diff line
@@ -30,7 +30,6 @@ import android.os.Handler;
import android.os.RemoteException;
import android.os.UserHandle;
import android.util.AttributeSet;
import android.util.Log;
import android.util.Slog;
import android.util.SparseBooleanArray;
import android.view.LayoutInflater;
@@ -173,9 +172,9 @@ class NavigationBarRecents extends LinearLayout {
                try {
                    manager.startActivityFromRecents(taskPersistentId, null /* options */);
                } catch (RemoteException e) {
                    Log.e(TAG, "Exception when activating a recent task", e);
                    Slog.e(TAG, "Exception when activating a recent task", e);
                } catch (IllegalArgumentException e) {
                    Log.e(TAG, "Exception when activating a recent task", e);
                    Slog.e(TAG, "Exception when activating a recent task", e);
                }
            }
        });
@@ -244,7 +243,7 @@ class NavigationBarRecents extends LinearLayout {
                ris = packageManager.queryIntentActivitiesAsUser(intentToResolve, 0, userId);
            }
            if (ris == null || ris.size() <= 0) {
                Log.e(TAG, "Failed to build intent for " + packageName);
                Slog.e(TAG, "Failed to build intent for " + packageName);
                return null;
            }
            return new ComponentName(ris.get(0).activityInfo.packageName,