Home
last modified time | relevance | path

Searched refs:typedArray (Results 1 – 17 of 17) sorted by relevance

/external/robolectric-shadows/robolectric/src/test/java/org/robolectric/shadows/
DShadowTypedArrayTest.java44 TypedArray typedArray = context.obtainStyledAttributes( in getInt_withFlags_shouldReturnValue() local
49 assertThat(typedArray.getInt(0, -1)).isEqualTo(0x33); in getInt_withFlags_shouldReturnValue()
59 TypedArray typedArray = context.obtainStyledAttributes( in getResourceId_shouldReturnActualValue() local
64 assertThat(typedArray.getResourceId(0, -1)).isEqualTo(R.id.snippet_text); in getResourceId_shouldReturnActualValue()
75 TypedArray typedArray = context.obtainStyledAttributes( in getFraction_shouldReturnGivenValue() local
80 assertThat(typedArray.getFraction(0, 100, 1, -1)) in getFraction_shouldReturnGivenValue()
91 TypedArray typedArray = context.obtainStyledAttributes( in getDimension_shouldReturnGivenValue() local
96 assertThat(typedArray.getDimension(0, -1)).isEqualTo(50f); in getDimension_shouldReturnGivenValue()
101 TypedArray typedArray = context.obtainStyledAttributes( in getDrawable_withExplicitColorValue_shouldReturnColorDrawable() local
106 ColorDrawable drawable = (ColorDrawable) typedArray.getDrawable(0); in getDrawable_withExplicitColorValue_shouldReturnColorDrawable()
[all …]
DShadowResourcesTest.java114 TypedArray typedArray = resources.obtainAttributes(attributeSet, new int[]{android.R.attr.id}); in obtainAttributes_shouldUseReferencedIdFromAttributeSet() local
115 assertThat(typedArray.getResourceId(0, -9)).isEqualTo(android.R.id.mask); in obtainAttributes_shouldUseReferencedIdFromAttributeSet()
121 TypedArray typedArray = resources.obtainAttributes(Robolectric.buildAttributeSet() in obtainAttributes() local
124 assertThat(typedArray).isNotNull(); in obtainAttributes()
125 assertThat(typedArray.peekValue(0).resourceId).isEqualTo(R.xml.shortcuts); in obtainAttributes()
136 TypedArray typedArray = resources in obtainAttributes_shouldReturnValuesFromAttributeSet() local
140 assertThat(typedArray.getDimension(0, 0)).isEqualTo(160f); in obtainAttributes_shouldReturnValuesFromAttributeSet()
141 assertThat(typedArray.getDimension(1, 0)).isEqualTo(12f); in obtainAttributes_shouldReturnValuesFromAttributeSet()
142 assertThat(typedArray.getString(2)).isEqualTo("A title!"); in obtainAttributes_shouldReturnValuesFromAttributeSet()
143 typedArray.recycle(); in obtainAttributes_shouldReturnValuesFromAttributeSet()
[all …]
DShadowAssetManagerTest.java136 TypedArray typedArray = in multiFormatAttributes_integerDecimalValue() local
139 typedArray.getValue(0, outValue); in multiFormatAttributes_integerDecimalValue()
148 TypedArray typedArray = in multiFormatAttributes_integerHexValue() local
151 typedArray.getValue(0, outValue); in multiFormatAttributes_integerHexValue()
160 TypedArray typedArray = in multiFormatAttributes_stringValue() local
163 typedArray.getValue(0, outValue); in multiFormatAttributes_stringValue()
172 TypedArray typedArray = in multiFormatAttributes_booleanValue() local
175 typedArray.getValue(0, outValue); in multiFormatAttributes_booleanValue()
DShadowThemeTest.java241 TypedArray typedArray = resources.newTheme().obtainStyledAttributes( in dimenRef() local
243 assertThat(typedArray.getDimensionPixelSize(0, -1)).isEqualTo(15); in dimenRef()
251 TypedArray typedArray = resources.newTheme().obtainStyledAttributes( in dimenRefRef() local
253 assertThat(typedArray.getDimensionPixelSize(0, -1)).isEqualTo(15); in dimenRefRef()
258 TypedArray typedArray = theme.obtainStyledAttributes(R.style.StyleA, new int[]{R.attr.string1}); in obtainStyledAttributes_shouldFindAttributeInDefaultStyle() local
259 assertThat(typedArray.getString(0)).isEqualTo("string 1 from style A"); in obtainStyledAttributes_shouldFindAttributeInDefaultStyle()
DShadowContextTest.java266 …TypedArray typedArray = context.obtainStyledAttributes(roboAttributeSet, new int[]{R.attr.quitKeyC… in obtainStyledAttributes_shouldExtractAttributesFromAttributeSet() local
267 assertThat(typedArray.getString(0)).isEqualTo("^q"); in obtainStyledAttributes_shouldExtractAttributesFromAttributeSet()
268 assertThat(typedArray.getInt(1, -1234)).isEqualTo(1 /* ungulate */); in obtainStyledAttributes_shouldExtractAttributesFromAttributeSet()
/external/robolectric-shadows/shadows/framework/src/main/java/org/robolectric/shadows/
DShadowTypedArray.java36 TypedArray typedArray; in create() local
38 typedArray = ReflectionHelpers.callConstructor(TypedArray.class, in create()
40 ReflectionHelpers.setField(typedArray, "mData", data); in create()
41 ReflectionHelpers.setField(typedArray, "mLength", len); in create()
42 ReflectionHelpers.setField(typedArray, "mIndices", indices); in create()
44 typedArray = ReflectionHelpers.callConstructor(TypedArray.class, in create()
51 ShadowTypedArray shadowTypedArray = Shadow.extract(typedArray); in create()
53 return typedArray; in create()
85 public static void dump(TypedArray typedArray) { in dump() argument
86 int[] data = ReflectionHelpers.getField(typedArray, "mData"); in dump()
[all …]
DShadowResources.java188 TypedArray typedArray = shadowAssetManager.getTypedArrayResource(realResources, id); in obtainTypedArray() local
189 if (typedArray != null) { in obtainTypedArray()
190 return typedArray; in obtainTypedArray()
DShadowLegacyAssetManager.java1219 …TypedArray typedArray = ShadowTypedArray.create(resources, attrs, data, indices, nextIndex, string… in attrsToTypedArray() local
1221 ShadowTypedArray shadowTypedArray = Shadow.extract(typedArray); in attrsToTypedArray()
1224 return typedArray; in attrsToTypedArray()
/external/skia/modules/canvaskit/
Dmemory.js26 CanvasKit.Malloc = function(typedArray, len) { argument
27 var byteLen = len * typedArray.BYTES_PER_ELEMENT;
33 typedArray: null,
43 if (this.typedArray && this.typedArray.length) {
44 return this.typedArray;
46 this.typedArray = new typedArray(CanvasKit.HEAPU8.buffer, ptr, len);
48 this.typedArray['_ck'] = true;
49 return this.typedArray;
63 mallocObj.typedArray = null;
/external/lottie/LottieSample/src/main/kotlin/com/airbnb/lottie/samples/views/
DMarquee.kt25 val typedArray = context.obtainStyledAttributes(it, R.styleable.Marquee, 0, 0) in <lambda>() constant
27 val titleRes = typedArray.getResourceId(R.styleable.Marquee_titleText, 0) in <lambda>()
32 val subtitleRes = typedArray.getResourceId(R.styleable.Marquee_subtitleText, 0) in <lambda>()
37 typedArray.recycle() in <lambda>()
DControlBarItemToggleView.kt30 … val typedArray = context.obtainStyledAttributes(it, R.styleable.ControlBarItemToggleView, 0, 0) in <lambda>() constant
32 val textRes = typedArray.getResourceId(R.styleable.ControlBarItemToggleView_text, 0) in <lambda>()
37 val drawableRes = typedArray.getResourceId(R.styleable.ControlBarItemToggleView_src, 0) in <lambda>()
44 typedArray.recycle() in <lambda>()
/external/setupcompat/main/java/com/google/android/setupcompat/template/
DSystemNavBarMixin.java96 TypedArray typedArray = in applyPartnerCustomizations() local
98 int defaultColor = typedArray.getColor(/* index= */ 0, /* defValue= */ 0); in applyPartnerCustomizations()
102 typedArray.recycle(); in applyPartnerCustomizations()
248 TypedArray typedArray = in showSystemBars() local
251 int statusBarColor = typedArray.getColor(0, 0); in showSystemBars()
252 int navigationBarColor = typedArray.getColor(1, 0); in showSystemBars()
263 typedArray.recycle(); in showSystemBars()
/external/setupdesign/main/src/com/google/android/setupdesign/items/
DRecyclerItemAdapter.java119 final TypedArray typedArray = in onCreateViewHolder() local
122 typedArray.getDrawable( in onCreateViewHolder()
126 typedArray.getDrawable(R.styleable.SudRecyclerItemAdapter_selectableItemBackground); in onCreateViewHolder()
139 typedArray.getDrawable(R.styleable.SudRecyclerItemAdapter_android_colorBackground); in onCreateViewHolder()
157 typedArray.recycle(); in onCreateViewHolder()
/external/mockito/src/main/java/org/mockito/internal/util/collections/
DHashCodeAndEqualsSafeSet.java110 public <T> T[] toArray(T[] typedArray) { in toArray() argument
111 …T[] array = typedArray.length >= size() ? typedArray : (T[]) newInstance(typedArray.getClass().get… in toArray()
/external/setupdesign/main/src/com/google/android/setupdesign/transition/
DTransitionHelper.java215 TypedArray typedArray = in applyForwardTransition() local
222 typedArray.getResourceId(/* index= */ 0, /* defValue= */ 0), in applyForwardTransition()
223 typedArray.getResourceId(/* index= */ 1, /* defValue= */ 0)); in applyForwardTransition()
224 typedArray.recycle(); in applyForwardTransition()
317 TypedArray typedArray = in applyBackwardTransition() local
325 typedArray.getResourceId(/* index= */ 0, /* defValue= */ 0), in applyBackwardTransition()
326 typedArray.getResourceId(/* index= */ 1, /* defValue= */ 0)); in applyBackwardTransition()
327 typedArray.recycle(); in applyBackwardTransition()
/external/setupcompat/main/java/com/google/android/setupcompat/util/
DSystemBarHelper.java192 final TypedArray typedArray = in showSystemBars() local
195 final int statusBarColor = typedArray.getColor(0, 0); in showSystemBars()
196 final int navigationBarColor = typedArray.getColor(1, 0); in showSystemBars()
199 typedArray.recycle(); in showSystemBars()
/external/skia/modules/canvaskit/npm_build/types/
Dindex.d.ts167 Malloc(typedArray: TypedArrayConstructor, len: number): MallocObj;