Loading core/java/android/widget/flags/flags.aconfig +0 −10 Original line number Diff line number Diff line package: "android.widget.flags" container: "system" flag { name: "enable_fading_view_group" namespace: "wear_systems" description: "FRP screen during OOBE must have fading and scaling animation in Wear Watches" bug: "348515581" metadata { purpose: PURPOSE_BUGFIX } } flag { name: "use_wear_material3_ui" namespace: "wear_frameworks" Loading core/java/com/android/internal/widget/ViewGroupFader.java +1 −2 Original line number Diff line number Diff line Loading @@ -23,7 +23,6 @@ import android.view.ViewGroup; import android.view.ViewGroup.MarginLayoutParams; import android.view.animation.BaseInterpolator; import android.view.animation.PathInterpolator; import android.widget.flags.Flags; /** * This class is ported from Loading Loading @@ -230,7 +229,7 @@ public class ViewGroupFader { continue; } if (Flags.enableFadingViewGroup() && Resources.getSystem().getBoolean( if (Resources.getSystem().getBoolean( com.android.internal.R.bool.config_enableViewGroupScalingFading)) { if (child instanceof ViewGroup) { updateListElementFades((ViewGroup) child, true); Loading core/tests/coretests/src/com/android/internal/widget/ViewGroupFaderTest.java +2 −22 Original line number Diff line number Diff line Loading @@ -20,12 +20,9 @@ import static androidx.test.platform.app.InstrumentationRegistry.getInstrumentat import android.content.Context; import android.content.res.Resources; import android.platform.test.annotations.EnableFlags; import android.platform.test.flag.junit.SetFlagsRule; import android.test.AndroidTestCase; import android.view.View; import android.view.ViewGroup; import android.widget.flags.Flags; import org.mockito.Mock; import org.mockito.MockitoAnnotations; Loading Loading @@ -59,8 +56,6 @@ public class ViewGroupFaderTest extends AndroidTestCase { @Mock private ViewGroupFader.ChildViewBoundsProvider mChildViewBoundsProvider; @Rule public final SetFlagsRule mSetFlagsRule = new SetFlagsRule(); @Before public void setUp() throws Exception { MockitoAnnotations.initMocks(this); Loading @@ -77,11 +72,10 @@ public class ViewGroupFaderTest extends AndroidTestCase { } /** This test checks that for each child of the parent viewgroup, * updateListElementFades is called for each of its child, when the Flag is set to true * updateListElementFades is called for each of its child */ @Test @EnableFlags(Flags.FLAG_ENABLE_FADING_VIEW_GROUP) public void testFadingAndScrollingAnimationWorking_FlagOn() { public void testFadingAndScrollingAnimationWorking() { mViewGroup.addView(mViewGroup1); mViewGroupFader.updateFade(); Loading @@ -90,18 +84,4 @@ public class ViewGroupFaderTest extends AndroidTestCase { verify(mockViewGroupFader).updateListElementFades((ViewGroup)child,true); } } /** This test checks that for each child of the parent viewgroup, * updateListElementFades is never called for each of its child, when the Flag is set to false */ @Test public void testFadingAndScrollingAnimationNotWorking_FlagOff() { mViewGroup.addView(mViewGroup1); mViewGroupFader.updateFade(); for (int i = 0; i < mViewGroup.getChildCount(); i++) { View child = mViewGroup.getChildAt(i); verify(mockViewGroupFader,never()).updateListElementFades((ViewGroup)child,true); } } } No newline at end of file Loading
core/java/android/widget/flags/flags.aconfig +0 −10 Original line number Diff line number Diff line package: "android.widget.flags" container: "system" flag { name: "enable_fading_view_group" namespace: "wear_systems" description: "FRP screen during OOBE must have fading and scaling animation in Wear Watches" bug: "348515581" metadata { purpose: PURPOSE_BUGFIX } } flag { name: "use_wear_material3_ui" namespace: "wear_frameworks" Loading
core/java/com/android/internal/widget/ViewGroupFader.java +1 −2 Original line number Diff line number Diff line Loading @@ -23,7 +23,6 @@ import android.view.ViewGroup; import android.view.ViewGroup.MarginLayoutParams; import android.view.animation.BaseInterpolator; import android.view.animation.PathInterpolator; import android.widget.flags.Flags; /** * This class is ported from Loading Loading @@ -230,7 +229,7 @@ public class ViewGroupFader { continue; } if (Flags.enableFadingViewGroup() && Resources.getSystem().getBoolean( if (Resources.getSystem().getBoolean( com.android.internal.R.bool.config_enableViewGroupScalingFading)) { if (child instanceof ViewGroup) { updateListElementFades((ViewGroup) child, true); Loading
core/tests/coretests/src/com/android/internal/widget/ViewGroupFaderTest.java +2 −22 Original line number Diff line number Diff line Loading @@ -20,12 +20,9 @@ import static androidx.test.platform.app.InstrumentationRegistry.getInstrumentat import android.content.Context; import android.content.res.Resources; import android.platform.test.annotations.EnableFlags; import android.platform.test.flag.junit.SetFlagsRule; import android.test.AndroidTestCase; import android.view.View; import android.view.ViewGroup; import android.widget.flags.Flags; import org.mockito.Mock; import org.mockito.MockitoAnnotations; Loading Loading @@ -59,8 +56,6 @@ public class ViewGroupFaderTest extends AndroidTestCase { @Mock private ViewGroupFader.ChildViewBoundsProvider mChildViewBoundsProvider; @Rule public final SetFlagsRule mSetFlagsRule = new SetFlagsRule(); @Before public void setUp() throws Exception { MockitoAnnotations.initMocks(this); Loading @@ -77,11 +72,10 @@ public class ViewGroupFaderTest extends AndroidTestCase { } /** This test checks that for each child of the parent viewgroup, * updateListElementFades is called for each of its child, when the Flag is set to true * updateListElementFades is called for each of its child */ @Test @EnableFlags(Flags.FLAG_ENABLE_FADING_VIEW_GROUP) public void testFadingAndScrollingAnimationWorking_FlagOn() { public void testFadingAndScrollingAnimationWorking() { mViewGroup.addView(mViewGroup1); mViewGroupFader.updateFade(); Loading @@ -90,18 +84,4 @@ public class ViewGroupFaderTest extends AndroidTestCase { verify(mockViewGroupFader).updateListElementFades((ViewGroup)child,true); } } /** This test checks that for each child of the parent viewgroup, * updateListElementFades is never called for each of its child, when the Flag is set to false */ @Test public void testFadingAndScrollingAnimationNotWorking_FlagOff() { mViewGroup.addView(mViewGroup1); mViewGroupFader.updateFade(); for (int i = 0; i < mViewGroup.getChildCount(); i++) { View child = mViewGroup.getChildAt(i); verify(mockViewGroupFader,never()).updateListElementFades((ViewGroup)child,true); } } } No newline at end of file