FloatingPaneView

class FloatingPaneView @JvmOverloads constructor(context: Context, val parentView: FloatingPaneLayout, attrs: AttributeSet? = null, defStyleAttr: Int = 0) : FrameLayout

Represents a floating pane view that can be displayed in different modes (bottom, side, floating) and can be minimized. It handles touch events for moving, resizing, and changing modes.

Parameters

context

The context in which the view is created.

parentView

The parent layout that contains this floating pane view.

attrs

The attributes of the XML tag that is inflating the view.

defStyleAttr

An attribute in the current theme that contains a reference to a style resource that supplies default values for the view. Can be 0 to not look for defaults.

Constructors

Link copied to clipboard
constructor(context: Context, parentView: FloatingPaneLayout, attrs: AttributeSet? = null, defStyleAttr: Int = 0)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

Functions

Link copied to clipboard

Adds a callback to be notified of floating pane events.

Link copied to clipboard
fun changePaneLayoutMode(requestMode: FloatingPane.FloatingPaneMode, invalidate: Boolean, isLongPress: Boolean, skipAnimate: Boolean)
Link copied to clipboard
fun enterMinimizeView(minimize: Boolean)

Enters or exits the minimize view.

Link copied to clipboard
Link copied to clipboard
fun hide(animate: Boolean)
Link copied to clipboard

Checks if the floating pane view is currently in a minimized state.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open override fun onTouchEvent(event: MotionEvent): Boolean
Link copied to clipboard

Removes all registered callbacks.

Link copied to clipboard

Removes a callback that was previously added.

Link copied to clipboard
fun setHaveAnotherMinimizeView(haveAnotherMinimizedView: Boolean)

Sets whether another minimize view exists. This is used to determine if alpha animations should be played when minimizing or un-minimizing.

Link copied to clipboard

Sets the height of the floating pane for a specific mode.

Link copied to clipboard

Sets the background resource for the result view in a specific mode.

Link copied to clipboard

Sets the width for a specific mode of the floating pane.

Link copied to clipboard
fun setTopLimitSize(newTopLimitSize: Int)

Sets the top limit size for the floating pane view. This method is used when the view is in certain modes like 'Bottom' or 'Side' to restrict how far up it can be moved or resized.

Link copied to clipboard
fun show(animate: Boolean)