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

Commit e83eb253 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Remove Dependency.get(MAIN_HANDLER) from SystemUIService"

parents 7c8b2750 6711ec9e
Loading
Loading
Loading
Loading
+13 −1
Original line number Diff line number Diff line
@@ -20,20 +20,32 @@ import android.annotation.NonNull;
import android.app.Service;
import android.content.Intent;
import android.os.Build;
import android.os.Handler;
import android.os.IBinder;
import android.os.Process;
import android.os.SystemProperties;
import android.util.Slog;

import com.android.internal.os.BinderInternal;
import com.android.systemui.dagger.qualifiers.MainHandler;
import com.android.systemui.shared.plugins.PluginManager;
import com.android.systemui.shared.plugins.PluginManagerImpl;

import java.io.FileDescriptor;
import java.io.PrintWriter;

import javax.inject.Inject;

public class SystemUIService extends Service {

    private final Handler mMainHandler;

    @Inject
    public SystemUIService(@MainHandler Handler mainHandler) {
        super();
        mMainHandler = mainHandler;
    }

    @Override
    public void onCreate() {
        super.onCreate();
@@ -56,7 +68,7 @@ public class SystemUIService extends Service {
                                    "uid " + uid + " sent too many Binder proxies to uid "
                                    + Process.myUid());
                        }
                    }, Dependency.get(Dependency.MAIN_HANDLER));
                    }, mMainHandler);
        }
    }

+7 −0
Original line number Diff line number Diff line
@@ -19,6 +19,7 @@ package com.android.systemui.dagger;
import android.app.Service;

import com.android.systemui.ImageWallpaper;
import com.android.systemui.SystemUIService;
import com.android.systemui.doze.DozeService;
import com.android.systemui.keyguard.KeyguardService;
import com.android.systemui.screenshot.TakeScreenshotService;
@@ -51,6 +52,12 @@ public abstract class DefaultServiceBinder {
    @ClassKey(KeyguardService.class)
    public abstract Service bindKeyguardService(KeyguardService service);

    /** */
    @Binds
    @IntoMap
    @ClassKey(SystemUIService.class)
    public abstract Service bindSystemUIService(SystemUIService service);

    /** */
    @Binds
    @IntoMap