Loading packages/SystemUI/src/com/android/systemui/dreams/DreamOverlayService.java +2 −1 Original line number Diff line number Diff line Loading @@ -17,6 +17,7 @@ package com.android.systemui.dreams; import static com.android.systemui.dreams.dagger.DreamModule.DREAM_OVERLAY_WINDOW_TITLE; import static com.android.systemui.dreams.dagger.DreamModule.DREAM_TOUCH_INSET_MANAGER; import android.content.ComponentName; import android.content.Context; Loading Loading @@ -161,7 +162,7 @@ public class DreamOverlayService extends android.service.dreams.DreamOverlayServ DreamOverlayStateController stateController, KeyguardUpdateMonitor keyguardUpdateMonitor, UiEventLogger uiEventLogger, TouchInsetManager touchInsetManager, @Named(DREAM_TOUCH_INSET_MANAGER) TouchInsetManager touchInsetManager, @Nullable @Named(LowLightDreamModule.LOW_LIGHT_DREAM_COMPONENT) ComponentName lowLightDreamComponent, DreamOverlayCallbackController dreamOverlayCallbackController, Loading packages/SystemUI/src/com/android/systemui/dreams/dagger/DreamModule.java +12 −1 Original line number Diff line number Diff line Loading @@ -31,11 +31,13 @@ import com.android.systemui.dreams.DreamOverlayNotificationCountProvider; import com.android.systemui.dreams.DreamOverlayService; import com.android.systemui.dreams.complication.dagger.ComplicationComponent; import com.android.systemui.dreams.touch.scrim.dagger.ScrimModule; import com.android.systemui.touch.TouchInsetManager; import dagger.Module; import dagger.Provides; import java.util.Optional; import java.util.concurrent.Executor; import javax.inject.Named; Loading @@ -55,7 +57,7 @@ public interface DreamModule { String DREAM_ONLY_ENABLED_FOR_DOCK_USER = "dream_only_enabled_for_dock_user"; String DREAM_OVERLAY_SERVICE_COMPONENT = "dream_overlay_service_component"; String DREAM_OVERLAY_ENABLED = "dream_overlay_enabled"; String DREAM_TOUCH_INSET_MANAGER = "dream_touch_inset_manager"; String DREAM_SUPPORTED = "dream_supported"; String DREAM_OVERLAY_WINDOW_TITLE = "dream_overlay_window_title"; Loading @@ -68,6 +70,15 @@ public interface DreamModule { return new ComponentName(context, DreamOverlayService.class); } /** * Provides a touch inset manager for dreams. */ @Provides @Named(DREAM_TOUCH_INSET_MANAGER) static TouchInsetManager providesTouchInsetManager(@Main Executor executor) { return new TouchInsetManager(executor); } /** * Provides whether dream overlay is enabled. */ Loading packages/SystemUI/src/com/android/systemui/touch/TouchInsetManager.java +1 −6 Original line number Diff line number Diff line Loading @@ -25,16 +25,12 @@ import android.view.ViewGroup; import androidx.concurrent.futures.CallbackToFutureAdapter; import com.android.systemui.dagger.qualifiers.Main; import com.google.common.util.concurrent.ListenableFuture; import java.util.HashMap; import java.util.HashSet; import java.util.concurrent.Executor; import javax.inject.Inject; /** * {@link TouchInsetManager} handles setting the touchable inset regions for a given View. This * is useful for passing through touch events for all but select areas. Loading Loading @@ -153,8 +149,7 @@ public class TouchInsetManager { * Default constructor. * @param executor An {@link Executor} to marshal all operations on. */ @Inject public TouchInsetManager(@Main Executor executor) { public TouchInsetManager(Executor executor) { mExecutor = executor; } Loading Loading
packages/SystemUI/src/com/android/systemui/dreams/DreamOverlayService.java +2 −1 Original line number Diff line number Diff line Loading @@ -17,6 +17,7 @@ package com.android.systemui.dreams; import static com.android.systemui.dreams.dagger.DreamModule.DREAM_OVERLAY_WINDOW_TITLE; import static com.android.systemui.dreams.dagger.DreamModule.DREAM_TOUCH_INSET_MANAGER; import android.content.ComponentName; import android.content.Context; Loading Loading @@ -161,7 +162,7 @@ public class DreamOverlayService extends android.service.dreams.DreamOverlayServ DreamOverlayStateController stateController, KeyguardUpdateMonitor keyguardUpdateMonitor, UiEventLogger uiEventLogger, TouchInsetManager touchInsetManager, @Named(DREAM_TOUCH_INSET_MANAGER) TouchInsetManager touchInsetManager, @Nullable @Named(LowLightDreamModule.LOW_LIGHT_DREAM_COMPONENT) ComponentName lowLightDreamComponent, DreamOverlayCallbackController dreamOverlayCallbackController, Loading
packages/SystemUI/src/com/android/systemui/dreams/dagger/DreamModule.java +12 −1 Original line number Diff line number Diff line Loading @@ -31,11 +31,13 @@ import com.android.systemui.dreams.DreamOverlayNotificationCountProvider; import com.android.systemui.dreams.DreamOverlayService; import com.android.systemui.dreams.complication.dagger.ComplicationComponent; import com.android.systemui.dreams.touch.scrim.dagger.ScrimModule; import com.android.systemui.touch.TouchInsetManager; import dagger.Module; import dagger.Provides; import java.util.Optional; import java.util.concurrent.Executor; import javax.inject.Named; Loading @@ -55,7 +57,7 @@ public interface DreamModule { String DREAM_ONLY_ENABLED_FOR_DOCK_USER = "dream_only_enabled_for_dock_user"; String DREAM_OVERLAY_SERVICE_COMPONENT = "dream_overlay_service_component"; String DREAM_OVERLAY_ENABLED = "dream_overlay_enabled"; String DREAM_TOUCH_INSET_MANAGER = "dream_touch_inset_manager"; String DREAM_SUPPORTED = "dream_supported"; String DREAM_OVERLAY_WINDOW_TITLE = "dream_overlay_window_title"; Loading @@ -68,6 +70,15 @@ public interface DreamModule { return new ComponentName(context, DreamOverlayService.class); } /** * Provides a touch inset manager for dreams. */ @Provides @Named(DREAM_TOUCH_INSET_MANAGER) static TouchInsetManager providesTouchInsetManager(@Main Executor executor) { return new TouchInsetManager(executor); } /** * Provides whether dream overlay is enabled. */ Loading
packages/SystemUI/src/com/android/systemui/touch/TouchInsetManager.java +1 −6 Original line number Diff line number Diff line Loading @@ -25,16 +25,12 @@ import android.view.ViewGroup; import androidx.concurrent.futures.CallbackToFutureAdapter; import com.android.systemui.dagger.qualifiers.Main; import com.google.common.util.concurrent.ListenableFuture; import java.util.HashMap; import java.util.HashSet; import java.util.concurrent.Executor; import javax.inject.Inject; /** * {@link TouchInsetManager} handles setting the touchable inset regions for a given View. This * is useful for passing through touch events for all but select areas. Loading Loading @@ -153,8 +149,7 @@ public class TouchInsetManager { * Default constructor. * @param executor An {@link Executor} to marshal all operations on. */ @Inject public TouchInsetManager(@Main Executor executor) { public TouchInsetManager(Executor executor) { mExecutor = executor; } Loading