/** * Gets the index of the drawable with the provided state set. * * @param stateSet the state set to look up * @return the index of the provided state set, or -1 if not found * @hide pending API council * @see #getStateDrawable(int) * @see #getStateSet(int) */ @DSComment("From safe class list") @DSSafe(DSCat.SAFE_LIST) @DSSource({DSSourceKind.SENSITIVE_UNCATEGORIZED}) @DSGenerator( tool_name = "Doppelganger", tool_version = "2.0", generated_on = "2013-12-30 12:34:11.128 -0500", hash_original_method = "410013485164C1DC2E995A85C1D3348C", hash_generated_method = "A49D72CF031B64EEE2017098206BB732") public int getStateDrawableIndex(int[] stateSet) { return mStateListState.indexOfStateSet(stateSet); }
@DSComment("From safe class list") @DSSafe(DSCat.SAFE_LIST) @DSGenerator( tool_name = "Doppelganger", tool_version = "2.0", generated_on = "2013-12-30 12:34:11.113 -0500", hash_original_method = "3B1FAED12170A69A129A87EF9824D4D4", hash_generated_method = "1CBF5E5B65D18CEA27C53CD9EBB977CC") @Override protected boolean onStateChange(int[] stateSet) { int idx = mStateListState.indexOfStateSet(stateSet); if (DEBUG) android.util.Log.i( TAG, "onStateChange " + this + " states " + Arrays.toString(stateSet) + " found " + idx); if (idx < 0) { idx = mStateListState.indexOfStateSet(StateSet.WILD_CARD); } if (selectDrawable(idx)) { return true; } return super.onStateChange(stateSet); }