Add @UnsupportedAppUsage annotations

For packages:
  android.widget

This is an automatically generated CL. See go/UnsupportedAppUsage
for more details.

Exempted-From-Owner-Approval: Mechanical changes to the codebase
which have been approved by Android API council and announced on
android-eng@

Bug: 110868826
Test: m
Change-Id: Ic61019b1df85448a158fc2ba55c326353222c6b9
diff --git a/core/java/android/widget/Switch.java b/core/java/android/widget/Switch.java
index 604575f..8bfc151 100644
--- a/core/java/android/widget/Switch.java
+++ b/core/java/android/widget/Switch.java
@@ -21,6 +21,7 @@
 import android.annotation.NonNull;
 import android.annotation.Nullable;
 import android.annotation.StyleRes;
+import android.annotation.UnsupportedAppUsage;
 import android.content.Context;
 import android.content.res.ColorStateList;
 import android.content.res.Resources;
@@ -93,12 +94,14 @@
     private static final int SERIF = 2;
     private static final int MONOSPACE = 3;
 
+    @UnsupportedAppUsage
     private Drawable mThumbDrawable;
     private ColorStateList mThumbTintList = null;
     private PorterDuff.Mode mThumbTintMode = null;
     private boolean mHasThumbTint = false;
     private boolean mHasThumbTintMode = false;
 
+    @UnsupportedAppUsage
     private Drawable mTrackDrawable;
     private ColorStateList mTrackTintList = null;
     private PorterDuff.Mode mTrackTintMode = null;
@@ -106,6 +109,7 @@
     private boolean mHasTrackTintMode = false;
 
     private int mThumbTextPadding;
+    @UnsupportedAppUsage
     private int mSwitchMinWidth;
     private int mSwitchPadding;
     private boolean mSplitTrack;
@@ -127,18 +131,21 @@
      * Width required to draw the switch track and thumb. Includes padding and
      * optical bounds for both the track and thumb.
      */
+    @UnsupportedAppUsage
     private int mSwitchWidth;
 
     /**
      * Height required to draw the switch track and thumb. Includes padding and
      * optical bounds for both the track and thumb.
      */
+    @UnsupportedAppUsage
     private int mSwitchHeight;
 
     /**
      * Width of the thumb's content region. Does not include padding or
      * optical bounds.
      */
+    @UnsupportedAppUsage
     private int mThumbWidth;
 
     /** Left bound for drawing the switch track and thumb. */
@@ -155,7 +162,9 @@
 
     private TextPaint mTextPaint;
     private ColorStateList mTextColors;
+    @UnsupportedAppUsage
     private Layout mOnLayout;
+    @UnsupportedAppUsage
     private Layout mOffLayout;
     private TransformationMethod2 mSwitchTransformationMethod;
     private ObjectAnimator mPositionAnimator;
@@ -1050,6 +1059,7 @@
         mPositionAnimator.start();
     }
 
+    @UnsupportedAppUsage
     private void cancelPositionAnimator() {
         if (mPositionAnimator != null) {
             mPositionAnimator.cancel();
@@ -1065,6 +1075,7 @@
      *
      * @param position new position between [0,1]
      */
+    @UnsupportedAppUsage
     private void setThumbPosition(float position) {
         mThumbPosition = position;
         invalidate();