FloatingAware

interface FloatingAware

Interface implemented by components that participate in a floating action container, exposing reference views and bounding insets to position projection backgrounds and reacting to floating background transition events.

Implementations can be supplied to a floating container layout (such as FloatingGroupLayout or FloatingToolbarLayout) via floatingAware to control how projection backgrounds align with reference views, as well as to receive callbacks during transition animations and configuration changes.

Default implementations like FloatingGroupAware and FloatingToolbarAware are provided for standard container and toolbar integration.

Inheritors

Types

Link copied to clipboard
object Companion
Link copied to clipboard

Identifies the relative position slot of a reference view within a floating container layout.

Functions

Link copied to clipboard

Returns a bitmask combining option flags (such as FLOATING_AWARE_OPTION_SKIP_REFER_VISIBLE_CHECK or FLOATING_AWARE_OPTION_SCALE_WITHOUT_CONTENT_VIEW) that configure floating layout behavior.

Link copied to clipboard

Returns the primary reference View associated with the specified PositionType slot, used by the floating container to position matching projection backgrounds.

Link copied to clipboard

Returns a Rect specifying the padding inset adjustments (left, top, right, bottom) applied to the projection background bounds matching the reference view at the given PositionType.

Link copied to clipboard

Returns a list of reference Views associated with the specified PositionType slot. Useful when a position slot corresponds to multiple views (e.g. menu items within an action menu).

Link copied to clipboard

Callback invoked when the configuration of the floating view changes (e.g., orientation or theme change).

Link copied to clipboard

Callback invoked when the floating background starts its hide transition animation.

Link copied to clipboard

Callback invoked when the floating background starts its show transition animation.