Home
last modified time | relevance | path

Searched refs:shadowBitmap (Results 1 – 9 of 9) sorted by relevance

/external/robolectric-shadows/shadows/framework/src/main/java/org/robolectric/shadows/
DShadowBitmap.java68 ShadowBitmap shadowBitmap = Shadow.extract(bitmap); in visualize() local
69 return shadowBitmap.getDescription(); in visualize()
214 ShadowBitmap shadowBitmap = Shadow.extract(scaledBitmap); in createBitmap() local
215 shadowBitmap.setDescription("Bitmap (" + width + " x " + height + ")"); in createBitmap()
217 shadowBitmap.width = width; in createBitmap()
218 shadowBitmap.height = height; in createBitmap()
219 shadowBitmap.config = config; in createBitmap()
220 shadowBitmap.setMutable(true); in createBitmap()
222 shadowBitmap.density = displayMetrics.densityDpi; in createBitmap()
224shadowBitmap.setPixels(new int[shadowBitmap.getHeight() * shadowBitmap.getWidth()], 0, shadowBitma… in createBitmap()
[all …]
DShadowBitmapFactory.java67 ShadowBitmap shadowBitmap = Shadow.extract(bitmap); in decodeResource() local
68 shadowBitmap.createdFromResId = id; in decodeResource()
80 ShadowBitmap shadowBitmap = Shadow.extract(bitmap); in decodeFile() local
81 shadowBitmap.createdFromPath = pathName; in decodeFile()
90 ShadowBitmap shadowBitmap = Shadow.extract(bitmap); in decodeFileDescriptor() local
91 shadowBitmap.createdFromFileDescriptor = fd; in decodeFileDescriptor()
129 ShadowBitmap shadowBitmap = Shadow.extract(bitmap); in decodeStream() local
130 shadowBitmap.createdFromStream = is; in decodeStream()
137 ShadowBitmap shadowBitmap = Shadow.extract(bitmap); in decodeByteArray() local
138 shadowBitmap.createdFromBytes = data; in decodeByteArray()
[all …]
DShadowCanvas.java62 ShadowBitmap shadowBitmap = Shadow.extract(targetBitmap); in appendDescription() local
63 shadowBitmap.appendDescription(s); in appendDescription()
67 ShadowBitmap shadowBitmap = Shadow.extract(targetBitmap); in getDescription() local
68 return shadowBitmap.getDescription(); in getDescription()
226 ShadowBitmap shadowBitmap = Shadow.extract(bitmap); in describeBitmap() local
227 appendDescription(shadowBitmap.getDescription()); in describeBitmap()
304 ShadowBitmap shadowBitmap = Shadow.extract(targetBitmap); in resetCanvasHistory() local
305 shadowBitmap.setDescription(""); in resetCanvasHistory()
DShadowThreadedRenderer.java23 ShadowBitmap shadowBitmap = Shadow.extract(bitmap); in createHardwareBitmap() local
24 shadowBitmap.setMutable(false); in createHardwareBitmap()
DShadowBitmapDrawable.java65 ShadowBitmap shadowBitmap = Shadow.extract(realBitmapDrawable.getBitmap()); in getCreatedFromResId() local
66 return shadowBitmap.getCreatedFromResId(); in getCreatedFromResId()
DShadowDrawable.java99 ShadowBitmap shadowBitmap = Shadow.extract(bitmap); in createFromResourceId() local
100 shadowBitmap.createdFromResId = resourceId; in createFromResourceId()
DShadowResources.java324 ShadowBitmap shadowBitmap = Shadow.extract(bitmap); in setCreatedFromResId() local
325 if (shadowBitmap.createdFromResId == -1) { in setCreatedFromResId()
332 shadowBitmap.setCreatedFromResId(id, resourceName); in setCreatedFromResId()
/external/robolectric-shadows/robolectric/src/test/java/org/robolectric/shadows/
DShadowBitmapFactoryTest.java38 ShadowBitmap shadowBitmap = shadowOf(bitmap); in decodeResource_shouldSetDescriptionAndCreatedFrom() local
39 …assertEquals("Bitmap for resource:org.robolectric:drawable/an_image", shadowBitmap.getDescription(… in decodeResource_shouldSetDescriptionAndCreatedFrom()
40 assertEquals(R.drawable.an_image, shadowBitmap.getCreatedFromResId()); in decodeResource_shouldSetDescriptionAndCreatedFrom()
69 ShadowBitmap shadowBitmap = shadowOf(bitmap); in decodeFile_shouldSetDescriptionAndCreatedFrom() local
70 assertEquals("Bitmap for file:/some/file.jpg", shadowBitmap.getDescription()); in decodeFile_shouldSetDescriptionAndCreatedFrom()
71 assertEquals("/some/file.jpg", shadowBitmap.getCreatedFromPath()); in decodeFile_shouldSetDescriptionAndCreatedFrom()
81 ShadowBitmap shadowBitmap = shadowOf(bitmap); in decodeStream_shouldSetDescriptionAndCreatedFrom() local
82 assertEquals("Bitmap for content:/path", shadowBitmap.getDescription()); in decodeStream_shouldSetDescriptionAndCreatedFrom()
83 assertEquals(inputStream, shadowBitmap.getCreatedFromStream()); in decodeStream_shouldSetDescriptionAndCreatedFrom()
93 ShadowBitmap shadowBitmap = shadowOf(bitmap); in decodeBytes_shouldSetDescriptionAndCreatedFrom() local
[all …]
DShadowBitmapTest.java111 ShadowBitmap shadowBitmap = shadowOf(newBitmap); in shouldCreateBitmapWithMatrix() local
112 assertThat(shadowBitmap.getDescription()) in shouldCreateBitmapWithMatrix()
115 assertThat(shadowBitmap.getCreatedFromBitmap()).isEqualTo(originalBitmap); in shouldCreateBitmapWithMatrix()
116 assertThat(shadowBitmap.getCreatedFromX()).isEqualTo(0); in shouldCreateBitmapWithMatrix()
117 assertThat(shadowBitmap.getCreatedFromY()).isEqualTo(0); in shouldCreateBitmapWithMatrix()
118 assertThat(shadowBitmap.getCreatedFromWidth()).isEqualTo(100); in shouldCreateBitmapWithMatrix()
119 assertThat(shadowBitmap.getCreatedFromHeight()).isEqualTo(50); in shouldCreateBitmapWithMatrix()
120 assertThat(shadowBitmap.getCreatedFromMatrix()).isEqualTo(m); in shouldCreateBitmapWithMatrix()
121 assertThat(shadowBitmap.getCreatedFromFilter()).isEqualTo(true); in shouldCreateBitmapWithMatrix()
122 assertThat(shadowBitmap.getWidth()).isEqualTo(50); in shouldCreateBitmapWithMatrix()
[all …]