Home
last modified time | relevance | path

Searched refs:styleable (Results 1 – 18 of 18) sorted by relevance

/cts/tests/tests/content/src/android/content/res/cts/
DTypedArrayTest.java62 final int[] attrs = R.styleable.style1; in setUp()
77 assertTrue(mTypedArray.getBoolean(R.styleable.style1_type1, false)); in testAttrsMethod()
78 assertFalse(mTypedArray.getBoolean(R.styleable.style1_type2, true)); in testAttrsMethod()
80 assertEquals(EXPECTEDCLOLOR, mTypedArray.getColor(R.styleable.style1_type3, DEFINT)); in testAttrsMethod()
86 mTypedArray.getColorStateList(R.styleable.style1_type4). in testAttrsMethod()
92 mTypedArray.getDimension(R.styleable.style1_type5, DEFFLOAT)); in testAttrsMethod()
94 mTypedArray.getDimensionPixelOffset(R.styleable.style1_type6, DEFINT)); in testAttrsMethod()
96 mTypedArray.getLayoutDimension(R.styleable.style1_type6, "type6")); in testAttrsMethod()
98 mTypedArray.getLayoutDimension(R.styleable.style1_type6, 0)); in testAttrsMethod()
100 mTypedArray.getDimensionPixelSize(R.styleable.style1_type7, DEFINT)); in testAttrsMethod()
[all …]
DConfigTest.java75 final int[] styleable, final String[] expectedValues) { in checkValue() argument
77 final TypedArray sa = theme.obtainStyledAttributes(resId, styleable); in checkValue()
78 for (int i = 0; i < styleable.length; i++) { in checkValue()
229 checkValue(res, bagRes, R.styleable.TestConfig, in checkPair()
243 R.styleable.TestConfig, new String[]{"bag default"}); in testAllEmptyConfigs()
250 R.styleable.TestConfig, new String[]{"bag xx"}); in testAllEmptyConfigs()
258 R.styleable.TestConfig, new String[]{"bag xx-rYY"}); in testAllEmptyConfigs()
265 R.styleable.TestConfig, new String[]{"bag mcc111"}); in testAllEmptyConfigs()
272 R.styleable.TestConfig, new String[]{"bag mnc222"}); in testAllEmptyConfigs()
279 R.styleable.TestConfig, new String[]{"bag notouch"}); in testAllEmptyConfigs()
[all …]
DPrimitiveTest.java36 final TypedArray sa = mContext.obtainStyledAttributes(resid, R.styleable.EnumStyle); in tryEnum()
37 final int value = sa.getInt(R.styleable.EnumStyle_testEnum, -1); in tryEnum()
53 final TypedArray sa = mContext.obtainStyledAttributes(resid, R.styleable.FlagStyle); in tryFlag()
54 final int value = sa.getInt(R.styleable.FlagStyle_testFlags, -1); in tryFlag()
DResourcesTest.java91 final TypedArray testTypedArray = mResources.obtainAttributes(set, R.styleable.Style1); in testObtainAttributes()
/cts/tests/tests/view/src/android/view/cts/
DContextThemeWrapperTest.java60 contextThemeWrapper.getTheme().obtainStyledAttributes(R.styleable.TextAppearance); in testAccessTheme()
112 TypedArray expectedTa = expected.obtainStyledAttributes(R.styleable.TextAppearance); in assertEqualsTextAppearanceStyle()
114 assertEquals(expectedTa.getColor(R.styleable.TextAppearance_textColor, defValue), in assertEqualsTextAppearanceStyle()
115 ta.getColor(R.styleable.TextAppearance_textColor, defValue)); in assertEqualsTextAppearanceStyle()
116 assertEquals(expectedTa.getColor(R.styleable.TextAppearance_textColorHint, defValue), in assertEqualsTextAppearanceStyle()
117 ta.getColor(R.styleable.TextAppearance_textColorHint, defValue)); in assertEqualsTextAppearanceStyle()
118 assertEquals(expectedTa.getColor(R.styleable.TextAppearance_textColorLink, defValue), in assertEqualsTextAppearanceStyle()
119 ta.getColor(R.styleable.TextAppearance_textColorLink, defValue)); in assertEqualsTextAppearanceStyle()
120 assertEquals(expectedTa.getColor(R.styleable.TextAppearance_textColorHighlight, defValue), in assertEqualsTextAppearanceStyle()
121 ta.getColor(R.styleable.TextAppearance_textColorHighlight, defValue)); in assertEqualsTextAppearanceStyle()
[all …]
DViewGroup_LayoutParamsTest.java53 int[] attrs = R.styleable.style1; in testSetBaseAttributes()
55 mockLayoutParams.setBaseAttributes(array, R.styleable.style1_type6, in testSetBaseAttributes()
56 R.styleable.style1_type7); in testSetBaseAttributes()
58 assertEquals(array.getDimensionPixelSize(R.styleable.style1_type6, defValue), in testSetBaseAttributes()
60 assertEquals(array.getDimensionPixelSize(R.styleable.style1_type7, defValue), in testSetBaseAttributes()
/cts/tests/tests/widget/src/android/widget/cts/
DTableLayout_LayoutParamsTest.java77 android.R.styleable.ViewGroup_Layout); in testSetBaseAttributes()
79 mockLayoutParams.setBaseAttributes(a, android.R.styleable.ViewGroup_Layout_layout_width, in testSetBaseAttributes()
80 android.R.styleable.ViewGroup_Layout_layout_height); in testSetBaseAttributes()
84 mockLayoutParams.setBaseAttributes(a, android.R.styleable.ViewGroup_Layout_layout_height, in testSetBaseAttributes()
85 android.R.styleable.ViewGroup_Layout_layout_width); in testSetBaseAttributes()
92 a = mTargetContext.obtainStyledAttributes(attrs, android.R.styleable.ViewGroup_Layout); in testSetBaseAttributes()
94 mockLayoutParams.setBaseAttributes(a, android.R.styleable.ViewGroup_Layout_layout_width, in testSetBaseAttributes()
95 android.R.styleable.ViewGroup_Layout_layout_height); in testSetBaseAttributes()
99 mockLayoutParams.setBaseAttributes(a, android.R.styleable.ViewGroup_Layout_layout_height, in testSetBaseAttributes()
100 android.R.styleable.ViewGroup_Layout_layout_width); in testSetBaseAttributes()
[all …]
DTableRow_LayoutParamsTest.java120 android.R.styleable.ViewGroup_Layout); in testSetBaseAttributes()
122 mockLayoutParams.setBaseAttributes(a, android.R.styleable.ViewGroup_Layout_layout_width, in testSetBaseAttributes()
123 android.R.styleable.ViewGroup_Layout_layout_height); in testSetBaseAttributes()
127 mockLayoutParams.setBaseAttributes(a, android.R.styleable.ViewGroup_Layout_layout_height, in testSetBaseAttributes()
128 android.R.styleable.ViewGroup_Layout_layout_width); in testSetBaseAttributes()
135 a = mTargetContext.obtainStyledAttributes(attrs, android.R.styleable.ViewGroup_Layout); in testSetBaseAttributes()
137 mockLayoutParams.setBaseAttributes(a, android.R.styleable.ViewGroup_Layout_layout_width, in testSetBaseAttributes()
138 android.R.styleable.ViewGroup_Layout_layout_height); in testSetBaseAttributes()
142 mockLayoutParams.setBaseAttributes(a, android.R.styleable.ViewGroup_Layout_layout_height, in testSetBaseAttributes()
143 android.R.styleable.ViewGroup_Layout_layout_width); in testSetBaseAttributes()
[all …]
DRadioGroup_LayoutParamsTest.java147 TypedArray a = mContext.obtainStyledAttributes(attrs, R.styleable.ViewGroup_MarginLayout); in testSetBaseAttributes()
149 R.styleable.ViewGroup_MarginLayout_layout_width, in testSetBaseAttributes()
150 R.styleable.ViewGroup_MarginLayout_layout_height); in testSetBaseAttributes()
/cts/tests/tests/preference2/src/android/preference2/cts/
DCustomDialogPreference.java44 TypedArray a = getContext().obtainStyledAttributes(attrs,R.styleable.CustPref); in init()
45 mTitle = a.getString(R.styleable.CustPref_title); in init()
46 mIcon = a.getDrawable(R.styleable.CustPref_icon); in init()
DCustomCheckBoxPreference.java48 TypedArray a = getContext().obtainStyledAttributes(attrs,R.styleable.CustPref); in init()
49 mTitle = a.getString(R.styleable.CustPref_title); in init()
50 mIcon = a.getDrawable(R.styleable.CustPref_icon); in init()
DCustomEditTextPreference.java48 TypedArray a = getContext().obtainStyledAttributes(attrs,R.styleable.CustPref); in init()
49 mTitle =a.getString(R.styleable.CustPref_title); in init()
50 mIcon = a.getDrawable(R.styleable.CustPref_icon); in init()
DCustomPreferenceGroup.java45 TypedArray a = getContext().obtainStyledAttributes(attrs,R.styleable.CustPref); in init()
46 setTitle(a.getString(R.styleable.CustPref_title)); in init()
47 setIcon(a.getDrawable(R.styleable.CustPref_icon)); in init()
DCustomSwitchPreference.java49 TypedArray a = getContext().obtainStyledAttributes(attrs,R.styleable.CustPref); in init()
50 mTitle =a.getString(R.styleable.CustPref_title); in init()
51 mIcon = a.getDrawable(R.styleable.CustPref_icon); in init()
DCustomPreference.java48 TypedArray a = getContext().obtainStyledAttributes(attrs,R.styleable.CustPref); in init()
49 setTitle(a.getString(R.styleable.CustPref_title)); in init()
50 setIcon(a.getDrawable(R.styleable.CustPref_icon)); in init()
/cts/tests/tests/app/src/android/app/cts/
DDialogTest.java100 d.getContext().getTheme().obtainStyledAttributes(R.styleable.TextAppearance); in testConstructor()
104 ta = w.getContext().getTheme().obtainStyledAttributes(R.styleable.TextAppearance); in testConstructor()
128 TypedArray expectedTa = expected.obtainStyledAttributes(R.styleable.TextAppearance); in assertTextAppearanceStyle()
130 assertEquals(expectedTa.getColor(R.styleable.TextAppearance_textColor, defValue), in assertTextAppearanceStyle()
131 ta.getColor(R.styleable.TextAppearance_textColor, defValue)); in assertTextAppearanceStyle()
132 assertEquals(expectedTa.getColor(R.styleable.TextAppearance_textColorHint, defValue), in assertTextAppearanceStyle()
133 ta.getColor(R.styleable.TextAppearance_textColorHint, defValue)); in assertTextAppearanceStyle()
134 assertEquals(expectedTa.getColor(R.styleable.TextAppearance_textColorLink, defValue), in assertTextAppearanceStyle()
135 ta.getColor(R.styleable.TextAppearance_textColorLink, defValue)); in assertTextAppearanceStyle()
136 assertEquals(expectedTa.getColor(R.styleable.TextAppearance_textColorHighlight, defValue), in assertTextAppearanceStyle()
[all …]
/cts/tests/tests/content/src/android/content/cts/
DContextTest.java115 .obtainStyledAttributes(android.R.styleable.View); in testObtainStyledAttributes()
123 android.R.styleable.TextAppearance); in testObtainStyledAttributes()
144 int[] attrs = android.R.styleable.DatePicker; in testObtainStyledAttributes()
/cts/apps/CtsVerifier/src/android/support/wearable/view/
DBoxInsetLayout.java401 … TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.BoxInsetLayout_Layout, 0, 0); in LayoutParams()
402 boxedEdges = a.getInt(R.styleable.BoxInsetLayout_Layout_layout_box, BOX_NONE); in LayoutParams()