Android APIs
public static abstract class

DrawableContainer.DrawableContainerState

extends Drawable.ConstantState
java.lang.Object
   ↳ android.graphics.drawable.Drawable.ConstantState
     ↳ android.graphics.drawable.DrawableContainer.DrawableContainerState

Class Overview

A ConstantState that can contain several Drawables. This class was made public to enable testing, and its visibility may change in a future release.

Summary

Public Methods
final int addChild(Drawable dr)
boolean canApplyTheme()
Return whether this constant state can have a theme applied.
boolean canConstantState()
int getChangingConfigurations()
Return a bit mask of configuration changes that will impact this drawable (and thus require completely reloading it).
final Drawable getChild(int index)
final int getChildCount()
final Drawable[] getChildren()
final int getConstantHeight()
final int getConstantMinimumHeight()
final int getConstantMinimumWidth()
final Rect getConstantPadding()
final int getConstantWidth()
final int getEnterFadeDuration()
final int getExitFadeDuration()
final int getOpacity()
void growArray(int oldSize, int newSize)
final boolean isConstantSize()
final boolean isStateful()
final void setConstantSize(boolean constant)
final void setEnterFadeDuration(int duration)
final void setExitFadeDuration(int duration)
final void setVariablePadding(boolean variable)
A boolean value indicating whether to use the maximum padding value of all frames in the set (false), or to use the padding value of the frame being shown (true).
Protected Methods
void computeConstantSize()
[Expand]
Inherited Methods
From class android.graphics.drawable.Drawable.ConstantState
From class java.lang.Object

Public Methods

public final int addChild (Drawable dr)

Added in API level 1

Parameters
dr Drawable
Returns
int

public boolean canApplyTheme ()

Added in API level 21

Return whether this constant state can have a theme applied.

Returns
boolean

public boolean canConstantState ()

Added in API level 1

Returns
boolean

public int getChangingConfigurations ()

Added in API level 1

Return a bit mask of configuration changes that will impact this drawable (and thus require completely reloading it).

Returns
int

public final Drawable getChild (int index)

Added in API level 19

Parameters
index int
Returns
Drawable

public final int getChildCount ()

Added in API level 1

Returns
int

public final Drawable[] getChildren ()

Added in API level 1

Returns
Drawable[]

public final int getConstantHeight ()

Added in API level 1

Returns
int

public final int getConstantMinimumHeight ()

Added in API level 1

Returns
int

public final int getConstantMinimumWidth ()

Added in API level 1

Returns
int

public final Rect getConstantPadding ()

Added in API level 1

Returns
Rect

public final int getConstantWidth ()

Added in API level 1

Returns
int

public final int getEnterFadeDuration ()

Added in API level 11

Returns
int

public final int getExitFadeDuration ()

Added in API level 11

Returns
int

public final int getOpacity ()

Added in API level 1

Returns
int

public void growArray (int oldSize, int newSize)

Added in API level 1

Parameters
oldSize int
newSize int

public final boolean isConstantSize ()

Added in API level 1

Returns
boolean

public final boolean isStateful ()

Added in API level 1

Returns
boolean

public final void setConstantSize (boolean constant)

Added in API level 1

Parameters
constant boolean

public final void setEnterFadeDuration (int duration)

Added in API level 11

Parameters
duration int

public final void setExitFadeDuration (int duration)

Added in API level 11

Parameters
duration int

public final void setVariablePadding (boolean variable)

Added in API level 1

A boolean value indicating whether to use the maximum padding value of all frames in the set (false), or to use the padding value of the frame being shown (true). Default value is false.

Parameters
variable boolean

Protected Methods

protected void computeConstantSize ()

Added in API level 11