/frameworks/base/core/tests/coretests/src/android/util/ |
D | StateSetTest.java | 31 int[] stateSet = new int[3]; in testStateSetPositiveMatches() local 34 stateSet[0] = 1; in testStateSetPositiveMatches() 35 assertTrue(StateSet.stateSetMatches(stateSpec, stateSet)); in testStateSetPositiveMatches() 37 stateSet[0] = 2; in testStateSetPositiveMatches() 38 assertFalse(StateSet.stateSetMatches(stateSpec, stateSet)); in testStateSetPositiveMatches() 41 assertFalse(StateSet.stateSetMatches(stateSpec, stateSet)); in testStateSetPositiveMatches() 43 stateSet[1] = 1; in testStateSetPositiveMatches() 44 assertTrue(StateSet.stateSetMatches(stateSpec, stateSet)); in testStateSetPositiveMatches() 46 stateSet[2] = 12345; in testStateSetPositiveMatches() 47 assertTrue(StateSet.stateSetMatches(stateSpec, stateSet)); in testStateSetPositiveMatches() [all …]
|
/frameworks/base/graphics/java/android/graphics/drawable/ |
D | StateListDrawable.java | 80 public void addState(int[] stateSet, Drawable drawable) { in addState() argument 82 mStateListState.addStateSet(stateSet, drawable); in addState() 94 protected boolean onStateChange(int[] stateSet) { in onStateChange() argument 95 final boolean changed = super.onStateChange(stateSet); in onStateChange() 97 int idx = mStateListState.indexOfStateSet(stateSet); in onStateChange() 99 + Arrays.toString(stateSet) + " found " + idx); in onStateChange() 274 public int getStateDrawableIndex(int[] stateSet) { in getStateDrawableIndex() argument 275 return mStateListState.indexOfStateSet(stateSet); in getStateDrawableIndex() 327 int addStateSet(int[] stateSet, Drawable drawable) { in addStateSet() argument 329 mStateSets[pos] = stateSet; in addStateSet() [all …]
|
D | AnimatedStateListDrawable.java | 109 public void addState(@NonNull int[] stateSet, @NonNull Drawable drawable, int id) { in addState() argument 114 mState.addStateSet(stateSet, drawable, id); in addState() 141 protected boolean onStateChange(int[] stateSet) { in onStateChange() argument 144 final int targetIndex = mState.indexOfKeyframe(stateSet); in onStateChange() 153 changed |= current.setState(stateSet); in onStateChange() 600 int addStateSet(@NonNull int[] stateSet, @NonNull Drawable drawable, int id) { in addStateSet() argument 601 final int index = super.addStateSet(stateSet, drawable); in addStateSet() 606 int indexOfKeyframe(@NonNull int[] stateSet) { in indexOfKeyframe() argument 607 final int index = super.indexOfStateSet(stateSet); in indexOfKeyframe()
|
D | Drawable.java | 677 public boolean setState(final int[] stateSet) { in setState() argument 678 if (!Arrays.equals(mStateSet, stateSet)) { in setState() 679 mStateSet = stateSet; in setState() 680 return onStateChange(stateSet); in setState()
|
D | GradientDrawable.java | 319 final int[] stateSet = getState(); in setStroke() local 320 color = colorStateList.getColorForState(stateSet, 0); in setStroke() 745 final int[] stateSet = getState(); 746 color = colorStateList.getColorForState(stateSet, 0); 753 protected boolean onStateChange(int[] stateSet) { 759 final int newColor = solidColors.getColorForState(stateSet, 0); 771 final int newColor = strokeColors.getColorForState(stateSet, 0);
|
D | RippleDrawable.java | 243 protected boolean onStateChange(int[] stateSet) { in onStateChange() argument 244 final boolean changed = super.onStateChange(stateSet); in onStateChange() 250 for (int state : stateSet) { in onStateChange()
|
D | ColorDrawable.java | 195 protected boolean onStateChange(int[] stateSet) { in onStateChange() argument
|
D | ShapeDrawable.java | 337 protected boolean onStateChange(int[] stateSet) { in onStateChange() argument
|
D | NinePatchDrawable.java | 592 protected boolean onStateChange(int[] stateSet) { in onStateChange() argument
|
D | BitmapDrawable.java | 703 protected boolean onStateChange(int[] stateSet) { in onStateChange() argument
|
D | VectorDrawable.java | 382 protected boolean onStateChange(int[] stateSet) { in onStateChange() argument
|
/frameworks/base/core/java/android/util/ |
D | StateSet.java | 148 public static boolean stateSetMatches(int[] stateSpec, int[] stateSet) { in stateSetMatches() argument 149 if (stateSet == null) { in stateSetMatches() 153 int stateSetSize = stateSet.length; in stateSetMatches() 170 final int state = stateSet[j]; in stateSetMatches()
|
/frameworks/support/v4/donut/android/support/v4/graphics/drawable/ |
D | DrawableWrapperDonut.java | 96 public boolean setState(final int[] stateSet) { in setState() argument 97 boolean handled = mDrawable.setState(stateSet); in setState() 98 handled = updateTint(stateSet) || handled; in setState()
|
/frameworks/support/v7/appcompat/src/android/support/v7/graphics/drawable/ |
D | DrawableWrapper.java | 91 public boolean setState(final int[] stateSet) { in setState() argument 92 return mDrawable.setState(stateSet); in setState()
|
/frameworks/support/v7/appcompat/src/android/support/v7/internal/widget/ |
D | ListViewCompat.java | 350 public boolean setState(int[] stateSet) { in setState() argument 352 return super.setState(stateSet); in setState()
|
/frameworks/base/core/java/android/content/res/ |
D | ColorStateList.java | 489 public int getColorForState(@Nullable int[] stateSet, int defaultColor) { in getColorForState() argument 493 if (StateSet.stateSetMatches(stateSpec, stateSet)) { in getColorForState()
|
/frameworks/base/core/java/android/widget/ |
D | DatePickerCalendarDelegate.java | 224 final int[][] stateSet = new int[][] {{ R.attr.state_activated }, {}}; in applyLegacyColorFixes() local 226 return new ColorStateList(stateSet, colors); in applyLegacyColorFixes()
|
D | ExpandableListView.java | 499 final int stateSet[] = pos.position.flatListPos == pos.groupMetadata.lastChildFlPos in getIndicator() local 502 indicator.setState(stateSet); in getIndicator()
|
D | SimpleMonthView.java | 455 final int[] stateSet = StateSet.get(stateMask); in drawDays() local 456 dayTextColor = mDayTextColor.getColorForState(stateSet, 0); in drawDays()
|
D | SearchView.java | 883 final int[] stateSet = focused ? FOCUSED_STATE_SET : EMPTY_STATE_SET; in updateFocusedState() local 886 searchPlateBg.setState(stateSet); in updateFocusedState() 890 submitAreaBg.setState(stateSet); in updateFocusedState()
|
D | TimePickerClockDelegate.java | 269 final int[][] stateSet = new int[][] {{ R.attr.state_activated }, {}}; in applyLegacyColorFixes() local 271 return new ColorStateList(stateSet, colors); in applyLegacyColorFixes()
|
/frameworks/support/v7/appcompat/src/android/support/v7/widget/ |
D | SearchView.java | 897 final int[] stateSet = focused ? FOCUSED_STATE_SET : EMPTY_STATE_SET; in updateFocusedState() local 900 searchPlateBg.setState(stateSet); in updateFocusedState() 904 submitAreaBg.setState(stateSet); in updateFocusedState()
|
/frameworks/support/graphics/drawable/static/src/android/support/graphics/drawable/ |
D | VectorDrawableCompat.java | 345 protected boolean onStateChange(int[] stateSet) { in onStateChange() argument
|