diff options
9 files changed, 62 insertions, 63 deletions
diff --git a/packages/SystemUI/multivalentTests/src/com/android/systemui/keyguard/ui/view/layout/sections/ClockSectionTest.kt b/packages/SystemUI/multivalentTests/src/com/android/systemui/keyguard/ui/view/layout/sections/ClockSectionTest.kt index 8058ecaaf364..1665895531b7 100644 --- a/packages/SystemUI/multivalentTests/src/com/android/systemui/keyguard/ui/view/layout/sections/ClockSectionTest.kt +++ b/packages/SystemUI/multivalentTests/src/com/android/systemui/keyguard/ui/view/layout/sections/ClockSectionTest.kt @@ -130,7 +130,7 @@ class ClockSectionTest : SysuiTestCase() { } @Test - @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testApplyDefaultConstraints_LargeClock_SplitShade() = kosmos.testScope.runTest { with(kosmos) { @@ -147,7 +147,7 @@ class ClockSectionTest : SysuiTestCase() { } @Test - @EnableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @EnableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testApplyDefaultConstraints_LargeClock_SplitShade_ReactiveVariantsOn() = kosmos.testScope.runTest { with(kosmos) { @@ -165,7 +165,7 @@ class ClockSectionTest : SysuiTestCase() { } @Test - @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testApplyDefaultConstraints_LargeClock_NonSplitShade() = kosmos.testScope.runTest { with(kosmos) { @@ -189,7 +189,7 @@ class ClockSectionTest : SysuiTestCase() { } @Test - @EnableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @EnableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testApplyDefaultConstraints_LargeClock_NonSplitShade_reactiveVariantsOn() = kosmos.testScope.runTest { with(kosmos) { @@ -262,7 +262,7 @@ class ClockSectionTest : SysuiTestCase() { } @Test - @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testApplyDefaultConstraints_SmallClock_SplitShade() = kosmos.testScope.runTest { with(kosmos) { @@ -286,7 +286,7 @@ class ClockSectionTest : SysuiTestCase() { } @Test - @EnableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @EnableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testApplyDefaultConstraints_SmallClock_SplitShade_ReactiveVariantsOn() = kosmos.testScope.runTest { with(kosmos) { @@ -311,7 +311,7 @@ class ClockSectionTest : SysuiTestCase() { } @Test - @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testApplyDefaultConstraints_SmallClock_NonSplitShade() = kosmos.testScope.runTest { with(kosmos) { @@ -334,7 +334,7 @@ class ClockSectionTest : SysuiTestCase() { } @Test - @EnableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @EnableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testApplyDefaultConstraints_SmallClock_NonSplitShade_ReactiveVariantsOn() = kosmos.testScope.runTest { with(kosmos) { diff --git a/packages/SystemUI/multivalentTests/src/com/android/systemui/keyguard/ui/view/layout/sections/SmartspaceSectionTest.kt b/packages/SystemUI/multivalentTests/src/com/android/systemui/keyguard/ui/view/layout/sections/SmartspaceSectionTest.kt index f9bed236ed5a..374bcbfb88cb 100644 --- a/packages/SystemUI/multivalentTests/src/com/android/systemui/keyguard/ui/view/layout/sections/SmartspaceSectionTest.kt +++ b/packages/SystemUI/multivalentTests/src/com/android/systemui/keyguard/ui/view/layout/sections/SmartspaceSectionTest.kt @@ -50,7 +50,7 @@ import org.mockito.MockitoAnnotations @RunWith(AndroidJUnit4::class) @SmallTest -@DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) +@DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) class SmartspaceSectionTest : SysuiTestCase() { private lateinit var underTest: SmartspaceSection @Mock private lateinit var keyguardClockViewModel: KeyguardClockViewModel @@ -102,7 +102,7 @@ class SmartspaceSectionTest : SysuiTestCase() { } @Test - @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testAddViews_notSmartspaceEnabled() { whenever(keyguardSmartspaceViewModel.isSmartspaceEnabled).thenReturn(false) val constraintLayout = ConstraintLayout(mContext) @@ -113,7 +113,7 @@ class SmartspaceSectionTest : SysuiTestCase() { } @Test - @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testAddViews_smartspaceEnabled_dateWeatherDecoupled() { whenever(keyguardSmartspaceViewModel.isDateWeatherDecoupled).thenReturn(true) underTest.addViews(constraintLayout) @@ -132,7 +132,7 @@ class SmartspaceSectionTest : SysuiTestCase() { } @Test - @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testConstraintsWhenShadeLayoutIsNotWide() { underTest.addViews(constraintLayout) underTest.applyConstraints(constraintSet) @@ -142,7 +142,7 @@ class SmartspaceSectionTest : SysuiTestCase() { } @Test - @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testConstraintsWhenShadeLayoutIsWide() { isShadeLayoutWide.value = true @@ -154,7 +154,7 @@ class SmartspaceSectionTest : SysuiTestCase() { } @Test - @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testConstraintsWhenNotHasCustomWeatherDataDisplay() { whenever(keyguardSmartspaceViewModel.isDateWeatherDecoupled).thenReturn(true) underTest.addViews(constraintLayout) @@ -169,7 +169,7 @@ class SmartspaceSectionTest : SysuiTestCase() { } @Test - @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testConstraintsWhenHasCustomWeatherDataDisplay() { hasCustomWeatherDataDisplay.value = true underTest.addViews(constraintLayout) @@ -180,7 +180,7 @@ class SmartspaceSectionTest : SysuiTestCase() { } @Test - @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testNormalDateWeatherVisibility() { isWeatherVisibleFlow.value = true underTest.addViews(constraintLayout) @@ -194,7 +194,7 @@ class SmartspaceSectionTest : SysuiTestCase() { } @Test - @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_VARIANTS) + @DisableFlags(com.android.systemui.shared.Flags.FLAG_CLOCK_REACTIVE_SMARTSPACE_LAYOUT) fun testCustomDateWeatherVisibility() { hasCustomWeatherDataDisplay.value = true underTest.addViews(constraintLayout) diff --git a/packages/SystemUI/src/com/android/systemui/keyguard/ui/binder/KeyguardBlueprintViewBinder.kt b/packages/SystemUI/src/com/android/systemui/keyguard/ui/binder/KeyguardBlueprintViewBinder.kt index 7a4be1d94980..fc5914b02e05 100644 --- a/packages/SystemUI/src/com/android/systemui/keyguard/ui/binder/KeyguardBlueprintViewBinder.kt +++ b/packages/SystemUI/src/com/android/systemui/keyguard/ui/binder/KeyguardBlueprintViewBinder.kt @@ -22,6 +22,7 @@ import androidx.constraintlayout.widget.ConstraintSet import androidx.lifecycle.Lifecycle import androidx.lifecycle.repeatOnLifecycle import com.android.app.tracing.coroutines.launchTraced as launch +import com.android.systemui.Flags import com.android.systemui.customization.R as customR import com.android.systemui.keyguard.shared.model.KeyguardBlueprint import com.android.systemui.keyguard.ui.view.layout.blueprints.transitions.IntraBlueprintTransition @@ -81,7 +82,7 @@ object KeyguardBlueprintViewBinder { logger.logConstraintSet(cs, clockViewModel) cs.applyTo(constraintLayout) - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { manuallySetDateWeatherConstraintsOnConstraintLayout( cs, constraintLayout, @@ -110,7 +111,7 @@ object KeyguardBlueprintViewBinder { } logger.logConstraintSet(cs, clockViewModel) cs.applyTo(constraintLayout) - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { manuallySetDateWeatherConstraintsOnConstraintLayout( cs, constraintLayout, @@ -168,7 +169,7 @@ object KeyguardBlueprintViewBinder { str1 = "${cs.getConstraint(smartspaceDateId).propertySet.alpha}" } - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { this.i({ "applyCsToSmartspaceWeather: vis=${getVisText(int1)}; alpha=$str1" }) { val smartspaceDateId = sharedR.id.weather_smartspace_view int1 = cs.getVisibility(smartspaceDateId) diff --git a/packages/SystemUI/src/com/android/systemui/keyguard/ui/binder/KeyguardRootViewBinder.kt b/packages/SystemUI/src/com/android/systemui/keyguard/ui/binder/KeyguardRootViewBinder.kt index b69df6843281..a0bbd0acba73 100644 --- a/packages/SystemUI/src/com/android/systemui/keyguard/ui/binder/KeyguardRootViewBinder.kt +++ b/packages/SystemUI/src/com/android/systemui/keyguard/ui/binder/KeyguardRootViewBinder.kt @@ -189,7 +189,7 @@ object KeyguardRootViewBinder { viewModel.translationY.collect { y -> childViews[burnInLayerId]?.translationY = y childViews[largeClockId]?.translationY = y - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { childViews[largeClockDateId]?.translationY = y childViews[largeClockWeatherId]?.translationY = y } diff --git a/packages/SystemUI/src/com/android/systemui/keyguard/ui/binder/KeyguardSmartspaceViewBinder.kt b/packages/SystemUI/src/com/android/systemui/keyguard/ui/binder/KeyguardSmartspaceViewBinder.kt index 76ece7d16642..def1ac8742da 100644 --- a/packages/SystemUI/src/com/android/systemui/keyguard/ui/binder/KeyguardSmartspaceViewBinder.kt +++ b/packages/SystemUI/src/com/android/systemui/keyguard/ui/binder/KeyguardSmartspaceViewBinder.kt @@ -80,7 +80,7 @@ object KeyguardSmartspaceViewBinder { } } - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { launch("$TAG#smartspaceViewModel.burnInLayerVisibility") { keyguardRootViewModel.burnInLayerVisibility.collect { visibility -> if (clockViewModel.isLargeClockVisible.value) { @@ -147,7 +147,7 @@ object KeyguardSmartspaceViewBinder { val dateView = constraintLayout.requireViewById<View>(sharedR.id.date_smartspace_view) addView(dateView) - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { val weatherView = constraintLayout.requireViewById<View>(sharedR.id.weather_smartspace_view) addView(weatherView) @@ -169,7 +169,7 @@ object KeyguardSmartspaceViewBinder { val dateView = constraintLayout.requireViewById<View>(sharedR.id.date_smartspace_view) removeView(dateView) - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { val weatherView = constraintLayout.requireViewById<View>(sharedR.id.weather_smartspace_view) removeView(weatherView) diff --git a/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/ClockSection.kt b/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/ClockSection.kt index 3d5dbb6df4c9..8a33c6471326 100644 --- a/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/ClockSection.kt +++ b/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/ClockSection.kt @@ -121,19 +121,19 @@ constructor( setAlpha(getNonTargetClockFace(clock).views, 0F) if (!keyguardClockViewModel.isLargeClockVisible.value) { - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { connect( sharedR.id.bc_smartspace_view, TOP, customR.id.lockscreen_clock_view, - BOTTOM + BOTTOM, ) } else { connect( sharedR.id.bc_smartspace_view, TOP, sharedR.id.date_smartspace_view, - BOTTOM + BOTTOM, ) } } else { @@ -161,7 +161,7 @@ constructor( ) if ( rootViewModel.isNotifIconContainerVisible.value.value && - keyguardClockViewModel.hasAodIcons.value + keyguardClockViewModel.hasAodIcons.value ) { createBarrier( R.id.weather_clock_date_and_icons_barrier_bottom, @@ -197,13 +197,13 @@ constructor( TOP, ) val largeClockTopMargin = - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { keyguardClockViewModel.getLargeClockTopMargin() + - getDimen(ENHANCED_SMARTSPACE_HEIGHT) + getDimen(ENHANCED_SMARTSPACE_HEIGHT) } else { keyguardClockViewModel.getLargeClockTopMargin() + - getDimen(DATE_WEATHER_VIEW_HEIGHT) + - getDimen(ENHANCED_SMARTSPACE_HEIGHT) + getDimen(DATE_WEATHER_VIEW_HEIGHT) + + getDimen(ENHANCED_SMARTSPACE_HEIGHT) } connect( customR.id.lockscreen_clock_view_large, @@ -229,9 +229,9 @@ constructor( PARENT_ID, START, context.resources.getDimensionPixelSize(customR.dimen.clock_padding_start) + - context.resources.getDimensionPixelSize( - customR.dimen.status_view_margin_horizontal - ), + context.resources.getDimensionPixelSize( + customR.dimen.status_view_margin_horizontal + ), ) val smallClockTopMargin = keyguardClockViewModel.getSmallClockTopMargin() create(R.id.small_clock_guideline_top, ConstraintSet.HORIZONTAL_GUIDELINE) @@ -243,18 +243,18 @@ constructor( val smallClockBottom = keyguardClockViewModel.getSmallClockTopMargin() + - context.resources.getDimensionPixelSize(customR.dimen.small_clock_height) + context.resources.getDimensionPixelSize(customR.dimen.small_clock_height) val marginBetweenSmartspaceAndNotification = context.resources.getDimensionPixelSize( R.dimen.keyguard_status_view_bottom_margin ) + - if (context.resources.getBoolean(R.bool.config_use_large_screen_shade_header)) { - largeScreenHeaderHelperLazy.get().getLargeScreenHeaderHeight() - } else { - 0 - } + if (context.resources.getBoolean(R.bool.config_use_large_screen_shade_header)) { + largeScreenHeaderHelperLazy.get().getLargeScreenHeaderHeight() + } else { + 0 + } - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { clockInteractor.setNotificationStackDefaultTop( (smallClockBottom + marginBetweenSmartspaceAndNotification).toFloat() ) @@ -263,8 +263,8 @@ constructor( getDimen(context, DATE_WEATHER_VIEW_HEIGHT).toFloat() clockInteractor.setNotificationStackDefaultTop( smallClockBottom + - dateWeatherSmartspaceHeight + - marginBetweenSmartspaceAndNotification + dateWeatherSmartspaceHeight + + marginBetweenSmartspaceAndNotification ) } } diff --git a/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/SmartspaceSection.kt b/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/SmartspaceSection.kt index cbd80b4f2c4b..37cc852ffe00 100644 --- a/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/SmartspaceSection.kt +++ b/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/SmartspaceSection.kt @@ -80,7 +80,7 @@ constructor( weatherView = smartspaceController.buildAndConnectWeatherView(constraintLayout, false) dateView = smartspaceController.buildAndConnectDateView(constraintLayout, false) as? ViewGroup - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { weatherViewLargeClock = smartspaceController.buildAndConnectWeatherView(constraintLayout, true) dateViewLargeClock = @@ -88,7 +88,7 @@ constructor( } pastVisibility = smartspaceView?.visibility ?: View.GONE constraintLayout.addView(smartspaceView) - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { dateView?.visibility = View.GONE weatherView?.visibility = View.GONE dateViewLargeClock?.visibility = View.GONE @@ -139,7 +139,7 @@ constructor( constraintSet.apply { constrainHeight(sharedR.id.date_smartspace_view, ConstraintSet.WRAP_CONTENT) constrainWidth(sharedR.id.date_smartspace_view, ConstraintSet.WRAP_CONTENT) - if (!com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (!com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { connect( sharedR.id.date_smartspace_view, ConstraintSet.START, @@ -167,7 +167,7 @@ constructor( smartspaceHorizontalPadding, ) if (keyguardClockViewModel.hasCustomWeatherDataDisplay.value) { - if (!com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (!com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { clear(sharedR.id.date_smartspace_view, ConstraintSet.TOP) connect( sharedR.id.date_smartspace_view, @@ -178,7 +178,7 @@ constructor( } } else { clear(sharedR.id.date_smartspace_view, ConstraintSet.BOTTOM) - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { connect( sharedR.id.bc_smartspace_view, ConstraintSet.TOP, @@ -201,7 +201,7 @@ constructor( } } - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { if (keyguardClockViewModel.isLargeClockVisible.value) { setVisibility(sharedR.id.weather_smartspace_view, GONE) setVisibility(sharedR.id.date_smartspace_view, GONE) @@ -335,7 +335,7 @@ constructor( } } - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { createBarrier( R.id.smart_space_barrier_bottom, Barrier.BOTTOM, @@ -370,7 +370,7 @@ constructor( if (!keyguardSmartspaceViewModel.isSmartspaceEnabled) return val list = - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { listOf( smartspaceView, dateView, @@ -401,7 +401,7 @@ constructor( val weatherId: Int val dateId: Int if ( - com.android.systemui.shared.Flags.clockReactiveVariants() && + com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout() && keyguardClockViewModel.isLargeClockVisible.value ) { weatherId = sharedR.id.weather_smartspace_view_large @@ -420,7 +420,7 @@ constructor( setVisibility(dateId, if (showDateView) VISIBLE else GONE) setAlpha(dateId, if (showDateView) 1f else 0f) - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { if (keyguardClockViewModel.isLargeClockVisible.value) { setVisibility(sharedR.id.weather_smartspace_view, GONE) setVisibility(sharedR.id.date_smartspace_view, GONE) diff --git a/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/transitions/ClockSizeTransition.kt b/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/transitions/ClockSizeTransition.kt index 67158e2e1476..434d7eadd742 100644 --- a/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/transitions/ClockSizeTransition.kt +++ b/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/transitions/ClockSizeTransition.kt @@ -297,14 +297,14 @@ class ClockSizeTransition( logger.e("No large clock set, falling back") addTarget(customR.id.lockscreen_clock_view_large) } - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { addTarget(sharedR.id.date_smartspace_view_large) addTarget(sharedR.id.weather_smartspace_view_large) } } else { logger.i("Adding small clock") addTarget(customR.id.lockscreen_clock_view) - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { addTarget(sharedR.id.date_smartspace_view) addTarget(sharedR.id.weather_smartspace_view) } @@ -386,7 +386,7 @@ class ClockSizeTransition( duration = if (isLargeClock) STATUS_AREA_MOVE_UP_MILLIS else STATUS_AREA_MOVE_DOWN_MILLIS interpolator = Interpolators.EMPHASIZED - if (!com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (!com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { addTarget(sharedR.id.date_smartspace_view) } addTarget(sharedR.id.bc_smartspace_view) diff --git a/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/transitions/DefaultClockSteppingTransition.kt b/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/transitions/DefaultClockSteppingTransition.kt index 827c61e4a579..0874b6da180e 100644 --- a/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/transitions/DefaultClockSteppingTransition.kt +++ b/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/transitions/DefaultClockSteppingTransition.kt @@ -25,14 +25,12 @@ import com.android.app.animation.Interpolators import com.android.systemui.plugins.clocks.ClockController import com.android.systemui.shared.R as sharedR -class DefaultClockSteppingTransition( - private val clock: ClockController, -) : Transition() { +class DefaultClockSteppingTransition(private val clock: ClockController) : Transition() { init { interpolator = Interpolators.LINEAR duration = KEYGUARD_STATUS_VIEW_CUSTOM_CLOCK_MOVE_DURATION_MS addTarget(clock.largeClock.view) - if (com.android.systemui.shared.Flags.clockReactiveVariants()) { + if (com.android.systemui.shared.Flags.clockReactiveSmartspaceLayout()) { addTarget(sharedR.id.date_smartspace_view_large) addTarget(sharedR.id.weather_smartspace_view_large) } @@ -56,7 +54,7 @@ class DefaultClockSteppingTransition( override fun createAnimator( sceneRoot: ViewGroup, startValues: TransitionValues?, - endValues: TransitionValues? + endValues: TransitionValues?, ): Animator? { if (startValues == null || endValues == null) { return null @@ -72,7 +70,7 @@ class DefaultClockSteppingTransition( clock.largeClock.animations.onPositionUpdated( fromLeft, direction, - animation.animatedFraction + animation.animatedFraction, ) } return anim |