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

Commit b19fcf3e authored by Chet Haase's avatar Chet Haase Committed by Android (Google) Code Review
Browse files

Merge "Add 'Property' object"

parents 608a23a0 b39f0516
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -1921,12 +1921,12 @@ package android.animation {
  public class FloatEvaluator implements android.animation.TypeEvaluator {
    ctor public FloatEvaluator();
    method public java.lang.Object evaluate(float, java.lang.Object, java.lang.Object);
    method public java.lang.Float evaluate(float, java.lang.Number, java.lang.Number);
  }
  public class IntEvaluator implements android.animation.TypeEvaluator {
    ctor public IntEvaluator();
    method public java.lang.Object evaluate(float, java.lang.Object, java.lang.Object);
    method public java.lang.Integer evaluate(float, java.lang.Integer, java.lang.Integer);
  }
  public abstract class Keyframe implements java.lang.Cloneable {
@@ -2012,7 +2012,7 @@ package android.animation {
  }
  public abstract interface TypeEvaluator {
    method public abstract java.lang.Object evaluate(float, java.lang.Object, java.lang.Object);
    method public abstract T evaluate(float, T, T);
  }
  public class ValueAnimator extends android.animation.Animator {
+35 −3
Original line number Diff line number Diff line
@@ -1968,12 +1968,12 @@ package android.animation {
  public class FloatEvaluator implements android.animation.TypeEvaluator {
    ctor public FloatEvaluator();
    method public java.lang.Object evaluate(float, java.lang.Object, java.lang.Object);
    method public java.lang.Float evaluate(float, java.lang.Number, java.lang.Number);
  }
  public class IntEvaluator implements android.animation.TypeEvaluator {
    ctor public IntEvaluator();
    method public java.lang.Object evaluate(float, java.lang.Object, java.lang.Object);
    method public java.lang.Integer evaluate(float, java.lang.Integer, java.lang.Integer);
  }
  public abstract class Keyframe implements java.lang.Cloneable {
@@ -2034,9 +2034,13 @@ package android.animation {
    method public java.lang.String getPropertyName();
    method public java.lang.Object getTarget();
    method public static android.animation.ObjectAnimator ofFloat(java.lang.Object, java.lang.String, float...);
    method public static android.animation.ObjectAnimator ofFloat(T, android.util.Property<T, java.lang.Float>, float...);
    method public static android.animation.ObjectAnimator ofInt(java.lang.Object, java.lang.String, int...);
    method public static android.animation.ObjectAnimator ofInt(T, android.util.Property<T, java.lang.Integer>, int...);
    method public static android.animation.ObjectAnimator ofObject(java.lang.Object, java.lang.String, android.animation.TypeEvaluator, java.lang.Object...);
    method public static android.animation.ObjectAnimator ofObject(T, android.util.Property<T, V>, android.animation.TypeEvaluator<V>, V...);
    method public static android.animation.ObjectAnimator ofPropertyValuesHolder(java.lang.Object, android.animation.PropertyValuesHolder...);
    method public void setProperty(android.util.Property);
    method public void setPropertyName(java.lang.String);
  }
@@ -2044,14 +2048,19 @@ package android.animation {
    method public android.animation.PropertyValuesHolder clone();
    method public java.lang.String getPropertyName();
    method public static android.animation.PropertyValuesHolder ofFloat(java.lang.String, float...);
    method public static android.animation.PropertyValuesHolder ofFloat(android.util.Property<?, java.lang.Float>, float...);
    method public static android.animation.PropertyValuesHolder ofInt(java.lang.String, int...);
    method public static android.animation.PropertyValuesHolder ofInt(android.util.Property<?, java.lang.Integer>, int...);
    method public static android.animation.PropertyValuesHolder ofKeyframe(java.lang.String, android.animation.Keyframe...);
    method public static android.animation.PropertyValuesHolder ofKeyframe(android.util.Property, android.animation.Keyframe...);
    method public static android.animation.PropertyValuesHolder ofObject(java.lang.String, android.animation.TypeEvaluator, java.lang.Object...);
    method public static android.animation.PropertyValuesHolder ofObject(android.util.Property, android.animation.TypeEvaluator<V>, V...);
    method public void setEvaluator(android.animation.TypeEvaluator);
    method public void setFloatValues(float...);
    method public void setIntValues(int...);
    method public void setKeyframes(android.animation.Keyframe...);
    method public void setObjectValues(java.lang.Object...);
    method public void setProperty(android.util.Property);
    method public void setPropertyName(java.lang.String);
  }
@@ -2060,7 +2069,7 @@ package android.animation {
  }
  public abstract interface TypeEvaluator {
    method public abstract java.lang.Object evaluate(float, java.lang.Object, java.lang.Object);
    method public abstract T evaluate(float, T, T);
  }
  public class ValueAnimator extends android.animation.Animator {
@@ -20097,6 +20106,10 @@ package android.util {
    method public void previousMonth();
  }
  public class NoSuchPropertyException extends java.lang.RuntimeException {
    ctor public NoSuchPropertyException(java.lang.String);
  }
  public class Pair {
    ctor public Pair(F, S);
    method public static android.util.Pair<A, B> create(A, B);
@@ -20132,6 +20145,16 @@ package android.util {
    method public abstract void println(java.lang.String);
  }
  public abstract class Property {
    ctor public Property(java.lang.Class<V>, java.lang.String);
    method public abstract V get(T);
    method public java.lang.String getName();
    method public java.lang.Class<V> getType();
    method public boolean isReadOnly();
    method public static android.util.Property<T, V> of(java.lang.Class<T>, java.lang.Class<V>, java.lang.String);
    method public void set(T, V);
  }
  public class SparseArray {
    ctor public SparseArray();
    ctor public SparseArray(int);
@@ -21878,6 +21901,11 @@ package android.view {
    field protected static final int[] PRESSED_SELECTED_STATE_SET;
    field protected static final int[] PRESSED_SELECTED_WINDOW_FOCUSED_STATE_SET;
    field protected static final int[] PRESSED_WINDOW_FOCUSED_STATE_SET;
    field public static android.util.Property ROTATION;
    field public static android.util.Property ROTATION_X;
    field public static android.util.Property ROTATION_Y;
    field public static android.util.Property SCALE_X;
    field public static android.util.Property SCALE_Y;
    field public static final int SCROLLBARS_INSIDE_INSET = 16777216; // 0x1000000
    field public static final int SCROLLBARS_INSIDE_OVERLAY = 0; // 0x0
    field public static final int SCROLLBARS_OUTSIDE_INSET = 50331648; // 0x3000000
@@ -21890,9 +21918,13 @@ package android.view {
    field public static final int SOUND_EFFECTS_ENABLED = 134217728; // 0x8000000
    field public static final int STATUS_BAR_HIDDEN = 1; // 0x1
    field public static final int STATUS_BAR_VISIBLE = 0; // 0x0
    field public static android.util.Property TRANSLATION_X;
    field public static android.util.Property TRANSLATION_Y;
    field protected static final java.lang.String VIEW_LOG_TAG = "View";
    field public static final int VISIBLE = 0; // 0x0
    field protected static final int[] WINDOW_FOCUSED_STATE_SET;
    field public static android.util.Property X;
    field public static android.util.Property Y;
  }
  public static class View.BaseSavedState extends android.view.AbsSavedState {
+4 −4
Original line number Diff line number Diff line
@@ -19,7 +19,7 @@ package android.animation;
/**
 * This evaluator can be used to perform type interpolation between <code>float</code> values.
 */
public class FloatEvaluator implements TypeEvaluator {
public class FloatEvaluator implements TypeEvaluator<Number> {

    /**
     * This function returns the result of linearly interpolating the start and end values, with
@@ -35,8 +35,8 @@ public class FloatEvaluator implements TypeEvaluator {
     * @return A linear interpolation between the start and end values, given the
     *         <code>fraction</code> parameter.
     */
    public Object evaluate(float fraction, Object startValue, Object endValue) {
        float startFloat = ((Number) startValue).floatValue();
        return startFloat + fraction * (((Number) endValue).floatValue() - startFloat);
    public Float evaluate(float fraction, Number startValue, Number endValue) {
        float startFloat = startValue.floatValue();
        return startFloat + fraction * (endValue.floatValue() - startFloat);
    }
}
 No newline at end of file
+4 −4
Original line number Diff line number Diff line
@@ -19,7 +19,7 @@ package android.animation;
/**
 * This evaluator can be used to perform type interpolation between <code>int</code> values.
 */
public class IntEvaluator implements TypeEvaluator {
public class IntEvaluator implements TypeEvaluator<Integer> {

    /**
     * This function returns the result of linearly interpolating the start and end values, with
@@ -35,8 +35,8 @@ public class IntEvaluator implements TypeEvaluator {
     * @return A linear interpolation between the start and end values, given the
     *         <code>fraction</code> parameter.
     */
    public Object evaluate(float fraction, Object startValue, Object endValue) {
        int startInt = ((Number) startValue).intValue();
        return (int) (startInt + fraction * (((Number) endValue).intValue() - startInt));
    public Integer evaluate(float fraction, Integer startValue, Integer endValue) {
        int startInt = startValue;
        return (int)(startInt + fraction * (endValue - startInt));
    }
}
 No newline at end of file
+151 −70

File changed.

Preview size limit exceeded, changes collapsed.

Loading