IBM Worklight v5.0.5 > API reference > IBM Worklight client-side API > JavaScript client-side APIWL.Client.onDock, WL.Client.onUndock
Specify widget behavior on docking and undocking, in Windows.
myOnDock = function () {
// Code here}
myOnUndock = function () {
// Code here}
Applicable only to widgets that are running in Vista Sidebar.
To specify widget behavior on docking and undocking, provide an implementation for the WL.Client.onDock and WL.Client.onUndock callback functions. Neither of these methods receive any parameters.
In the initialization function, assign myOndock() and myOnUnDock() to WL.Client.onDock() and WL.Client.onUndock():
WL.Client.onDock = myOnDock; WL.Client.onUndock = myOnUndock;
Parent JavaScript client-side API