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

Commit 8566c3bd authored by George Lin's avatar George Lin
Browse files

Remove unused context in StatsLogUserEventLogger

Test: Build success.
Bug: 291325750
Change-Id: I83af7b835f1d9381032fb3e97416e503390172a9
parent 06523e97
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -37,7 +37,6 @@ import static com.android.wallpaper.util.LaunchSourceUtils.LAUNCH_SOURCE_TIPS;
import static com.android.wallpaper.util.LaunchSourceUtils.WALLPAPER_LAUNCH_SOURCE;

import android.app.WallpaperManager;
import android.content.Context;
import android.content.Intent;
import android.stats.style.StyleEnums;
import android.text.TextUtils;
@@ -59,15 +58,12 @@ import java.util.Objects;
 */
public class StatsLogUserEventLogger extends NoOpUserEventLogger implements ThemesUserEventLogger {

    private final Context mContext;
    private final WallpaperPreferences mPreferences;
    private final WallpaperStatusChecker mWallpaperStatusChecker;

    public StatsLogUserEventLogger(
            Context appContext,
            WallpaperPreferences preferences,
            WallpaperStatusChecker wallpaperStatusChecker) {
        mContext = appContext;
        mPreferences = preferences;
        mWallpaperStatusChecker = wallpaperStatusChecker;
    }
+2 −4
Original line number Diff line number Diff line
@@ -183,12 +183,10 @@ open class ThemePickerInjector : WallpaperPicker2Injector(), CustomizationInject

    @Synchronized
    override fun getUserEventLogger(context: Context): ThemesUserEventLogger {
        val appContext = context.applicationContext
        return userEventLogger as? ThemesUserEventLogger
            ?: StatsLogUserEventLogger(
                    appContext,
                    getPreferences(appContext),
                    getWallpaperStatusChecker(appContext),
                    getPreferences(context.applicationContext),
                    getWallpaperStatusChecker(context.applicationContext),
                )
                .also { userEventLogger = it }
    }