Package org.robolectric.shadows
Class ShadowDrawable
java.lang.Object
org.robolectric.shadows.ShadowDrawable
- Direct Known Subclasses:
ShadowBitmapDrawable,ShadowGradientDrawable,ShadowNativeAnimatedImageDrawable,ShadowNativeAnimatedVectorDrawable,ShadowNativeVectorDrawable,ShadowPaintDrawable,ShadowStateListDrawable,ShadowVectorDrawable
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic DrawablecreateFromResourceId(int resourceId) Deprecated.intprotected voidprotected voidsetCreatedFromResId(int createdFromResId, String resourceName) voidvalidate()boolean
-
Constructor Details
-
ShadowDrawable
public ShadowDrawable()
-
-
Method Details
-
createFromResourceId
Deprecated.useContextCompat.getDrawable(context, resourceId)Returns an invalid Drawable with the given the resource id. -
setCreatedFromResId
-
getInputStream
-
invalidateSelf
-
getCreatedFromResId
public int getCreatedFromResId() -
wasInvalidated
public boolean wasInvalidated() -
validate
public void validate()
-
ContextCompat.getDrawable(context, resourceId)