updateButtonPosition

fun updateButtonPosition(position: Rect)

Updates the button position using a rectangular bounds.

This method sets the button position to the center of the provided rectangle. The position is used by animation formats that require knowledge of the interaction point for effects like circular reveals.

Parameters

position

The rectangular bounds of the theme toggle button.


Updates the button position using screen coordinates.

This method directly sets the button position to the specified point. The position is used by animation formats that require knowledge of the interaction point for effects like circular reveals.

Parameters

position

The screen coordinates of the theme toggle button.