Dockable Interface
Prev | Chapter 3. API Changes | Next

## Dockable Interface

A new boolean attribute, `MOVABLE`, can now be specified for `DOCKABLE` tags in the `dockables.xml` file. This attribute specifies the behavior when the docking position of the dockable window is changed. If true, the existing instance of the dockable window is moved to the new docking position, thus maintaining its state after the move (this is the new behavior). If false, the BeanShell code is invoked to get the instance to put in the new docking position (this is the existing behavior). The BeanShell code typically returns a new instance of the dockable, cause the state to be lost as a result of the change in docking position. The default value of this attribute is false for backward compatibility.

A new interface, DockableWindow, is introduced for `MOVABLE` dockable windows to be notified before their docking position is changed. This enables dockable windows to react to this change, e.g. by changing their layout depending on whether they are docked at the top/bottom or the left/right. This interface is meaningless (for now) for non-MOVABLE dockable windows.

A new Service, DockableWindowManagerProvier is introduced to permit plugins to offer alternate dockable frameworks, replacing the legacy dockables that are starting to look rather old.

Prev | Up | Next
Plugin API changes | Home | Chapter 4. The core plugins