Widget.dock()

Availability

Flash Player 7 + TheSpringBox 1.0.7

Usage

Widget.dock(toggle:Boolean) : Void;

Parameters

toggle - A Boolean; true to force the widget to dock; false the force it to undock.

Returns

Nothing.

Description

Method; toggles to dock state of the widget. if the widget is docked when calling Widget.dock(false) the widget will undock and be centered on the screen.

Example

In the below example, a button is used to toggle the docked state of the widget window:

btnToggleDock.onRelease = function() {
  Widget.dock(!Widget.isDocked);
};