public final class

CompositeDrawable.ChildDrawable

extends java.lang.Object

 java.lang.Object

↳androidx.leanback.graphics.CompositeDrawable.ChildDrawable

Overview

Wrapper class holding a drawable object and BoundsRule to update drawable bounds when parent bound changes.

Summary

Fields
public static final <any>BOTTOM_ABSOLUTE

Implementation of for overrideBottom attribute.

public static final <any>BOTTOM_FRACTION

Implementation of for overwriting the bottom attribute of BoundsRule associated with this CompositeDrawable.ChildDrawable.

public static final <any>LEFT_ABSOLUTE

Implementation of for overrideLeft attribute.

public static final <any>LEFT_FRACTION

Implementation of for overwriting the bottom attribute of BoundsRule associated with this CompositeDrawable.ChildDrawable.

public static final <any>RIGHT_ABSOLUTE

Implementation of for overrideRight attribute.

public static final <any>RIGHT_FRACTION

Implementation of for overwriting the bottom attribute of BoundsRule associated with this CompositeDrawable.ChildDrawable.

public static final <any>TOP_ABSOLUTE

Implementation of for overrideTop attribute.

public static final <any>TOP_FRACTION

Implementation of for overwriting the bottom attribute of BoundsRule associated with this CompositeDrawable.ChildDrawable.

Constructors
publicChildDrawable(Drawable drawable, CompositeDrawable parent)

Methods
public BoundsRulegetBoundsRule()

Returns the instance of BoundsRule.

public DrawablegetDrawable()

Returns the Drawable.

public voidrecomputeBounds()

After changing the BoundsRule, user should call this function for the drawable to recalculate its bounds.

from java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Fields

public static final <any> TOP_ABSOLUTE

Implementation of for overrideTop attribute.

public static final <any> BOTTOM_ABSOLUTE

Implementation of for overrideBottom attribute.

public static final <any> LEFT_ABSOLUTE

Implementation of for overrideLeft attribute.

public static final <any> RIGHT_ABSOLUTE

Implementation of for overrideRight attribute.

public static final <any> TOP_FRACTION

Implementation of for overwriting the bottom attribute of BoundsRule associated with this CompositeDrawable.ChildDrawable. This allows users to change the bounds rules as a percentage of parent size. This is preferable over CompositeDrawable.ChildDrawable.TOP_ABSOLUTE when the exact start/end position of scroll movement isn't available at compile time.

public static final <any> BOTTOM_FRACTION

Implementation of for overwriting the bottom attribute of BoundsRule associated with this CompositeDrawable.ChildDrawable. This allows users to change the bounds rules as a percentage of parent size. This is preferable over CompositeDrawable.ChildDrawable.BOTTOM_ABSOLUTE when the exact start/end position of scroll movement isn't available at compile time.

public static final <any> LEFT_FRACTION

Implementation of for overwriting the bottom attribute of BoundsRule associated with this CompositeDrawable.ChildDrawable. This allows users to change the bounds rules as a percentage of parent size. This is preferable over CompositeDrawable.ChildDrawable.LEFT_ABSOLUTE when the exact start/end position of scroll movement isn't available at compile time.

public static final <any> RIGHT_FRACTION

Implementation of for overwriting the bottom attribute of BoundsRule associated with this CompositeDrawable.ChildDrawable. This allows users to change the bounds rules as a percentage of parent size. This is preferable over CompositeDrawable.ChildDrawable.RIGHT_ABSOLUTE when the exact start/end position of scroll movement isn't available at compile time.

Constructors

public ChildDrawable(Drawable drawable, CompositeDrawable parent)

Methods

public BoundsRule getBoundsRule()

Returns the instance of BoundsRule.

public Drawable getDrawable()

Returns the Drawable.

public void recomputeBounds()

After changing the BoundsRule, user should call this function for the drawable to recalculate its bounds.