Version 1.1.1

Version 1.1.1 is only maintenance work like finishing the ~100 Todos that pilled up in the last years…

Version 1.1.1p1
WARNING: 1.1.1p1 is not very stable, but there are bugfixes which could be important for some people.

[ul]
[li] - Bugfix: If a CDockable is made visible without a known location, then the default location stored in CLocationModeManager is checked as well.
[/li][li] - Bugfix: CLocationMode.getCLocation did return null even if there was enough information to return a non-null result.
[/li][li] - API: MultipleCDockables are now registered at the DockFrontend just like SingleCDockables. This adds better support for persistent location storage to MultipleCDockable.
[/li][li] - API: CDockable has new method “getAutoBaseLocation” which tells where exactly an invisible dockable will appear.
[/li][li] - Bugfix: The identifier for storing meta information of missing MultipleCDockables was calculated the wrong way resulting in an invalid identifier. This prevented the framework from storing location information.
[/li][li] - API: CControlPerspective has additional methods to write and read a single perspective, aka “import/export feature”.
[/li][li] - API: DefaultMultipleCDockable now accepts “null” as factory, null will be replaced by “NullMultipleCDockableFactory.NULL”
[/li][li] ! API: FlapLayoutManager has an additional property “isHoldSwitchable” that tells whether the “sticky” button is visible for some Dockable
[/li][li] - API: CDockable has a new property “isMinimizedHoldSwitchable” that tells whether the “sticky” button is visible for some Dockable
[/li][li] - API: CDockable has a new action key “ACTION_KEY_MINIMIZED_HOLD” which allows client to replace the sticky action shown when a dockable is minimized
[/li][li] - Bugfix: DockHierarchyLock.runOnRelease has a timeout for how long the method blocks if not called from the EDT. This prevents a deadlock if some unfortunate chain of events happened.
[/li][li] - Bugfix: LockedResizeLayoutManager should no longer throw NPEs when accessed in a multi threading application
[/li][li] - API: DefaultIconScheme now also stores custom DockIconBridges
[/li][li] - API: The icon used when there are too many Dockables on a StackDockStation and the EclipseTheme is used, now depends on the actual number of overflowing Dockables. Clients can use their own icon by installing a DockIconBridge for type TabMenuDockIcon.KIND_TAB_MENU.
[/li][li] ! API: Added method “dragged”, “dragging”, and “searched” to VetoableDockRelocatorListener, the method “draging” was removed and got replaced by “searched”.
[/li][li] - API: New method DockController.getRepresentative searches for all DockElementRepresentatives of a DockElement. Also DockUtilities.getShowingComponent now checks the DockElementRepresentatives as well.
[/li][li] - API: The default set of icons is now loaded in DockController.createDefaultIconScheme
[/li][li] - API: New property IconManager.MINIMUM_ICON_SIZE tells the framework how small icons can get. The size of some Components does not shrink below this number.
[/li][li] - Bugfix: The unique identifier for LookAndFeels known to the LookAndFeelList no longer depends on the order in which the LookAndFeels are found.
[/li][li] ! API: Extracted inner classes of MenuLineLayout for more flexibility.
[/li][li] ! API: TabsLayoutBlock is now an interface. The new factory MenuLineLayoutFactory creates the different LayoutBlocks used by the MenuLineLayout, clients can make use of the MenuLineLayoutFactory to alter the behavior of a single block of components.
[/li][li] - API: If using the MenuLineLayout: the new MenuLineOrder (created by MenuLineLayoutFactory) defines order, weight, alignment and extend of tabs, menus and info component
[/li][li] - API: FlatTheme and BubbleTheme now also support the MenuLineLayout, they now install a MenuLineLayout instead of a RowLayout
[/li][li] - Bugfix: Calling CControlPerspective.getPerspective on an application with no Dockables failed.
[/li][li] - Bugfix: DefaultSplitLayoutManager should no longer throw NPE when a node returns “null” as minimum size
[/li][li] ! API: New interface DockFrontendPerspective should allow clients to modify a perspective related to a DockFrontend more easily
[/li][li] - API: PlaceholderMap now also allows to store Paths
[/li][li] - API: SplitDockStation.get/setPlaceholders is now implemented
[/li][/ul]

{Removal of deprecated items}
[ul]
[li] ! API: SizeManager and all subclasses have been removed without replacement. They were created to support persistent storage of the layout of a SplitDockStation, this job is now done by placeholders.
[/li][li] ! API: DockFrontend.add replaced by addDockable
[/li][li] ! API: CControl removed several methods to add/remove dockables and factories
[/li][li] ! API: CWorkingArea removed methods “isTitleSuppressed/setTitleSuppressed”, these methods are replaced by “is/setTitleShown”
[/li][li] ! API: SingleCDockableBackupFactory replaced by SingleCDockableFactory
[/li][li] ! API: Methods related to UIListener moved from DockController to ThemeManager
[/li][li] ! API: DockController.getFocusObserver replaced by getMouseFocusObserver
[/li][li] ! API: Several methods from DockUI (like “getCombiner”) replaced by methods from the ThemeManager
[/li][li] ! API: DockRelocatorListener got completely replaced by VetoableDockRelocatorListener
[/li][/ul]

Beni, thanks for everything. DockingFrames just got better! :slight_smile: Brilliant!
Keep up with good work. If there is any way I can help, let me know.

Hid dejan. Any kind of feedback and ideas are welcome :slight_smile:

Any plan to push it to the maven repository http://forum.byte-welt.net/showthread.php?t=3070 ?

Should have happened automatically… but it didn’t. I’ll send a mail to Andrei, he should know more.

We are still working on the maven repository (creating new accounts, upgrading the tool chain). Should be finished sometimes during this week.

The issues with Java 7 are still pending, but I did not forget them.

[v.1.1.1p2]
[ul]
[li]! API: All resources (icons, localization) have been put into subfolders, this should prevent any collision of resources with any other project.
[/li][li]! API: The drag’n’drop interface of DockStation has been heavily modified. All the methods related to drag and drop have been removed except “prepareDrop”. “prepareDrop” now returns an object that is used to execute the operation.
[/li][li]! API: Renamed StackDockComponent.setTabPlacemenet to setDockTabPlacement to prevent collision of names with JTabbedPane
[/li][li]! API: The DockableDisplayer can now influence a drag and drop operation through a “DisplayerCombinerTarget”. This allows displayers that show a tab (like in the EclipseTheme) to place a Dockable “left” or “right” to the existing dockable. Also the displayer can now paint markings to help the user to find out, what will happen.
[/li][li]- API: New property StackDockStation.IMMUTABLE_SELECTED_INDEX prevents the StackDockStation from switching the selection index when dropping a Dockable (but has no effect on the FocusManager!).
[/li][li]- Bugfix: EclipseStationPaint did dispose Graphics context that should not be disposed
[/li][/ul]

Two updates - in the same post but not on the same day. The forum was offline, but EagleEye fixed it. Next week I have some free days and I intend to do some more work than one bugfix this time :wink:

Version 1.1.1p3
[ul]
[li]! API: CAction now wrapps around a CommonDockAction and no longer a DockAction. This allows clients to use annotations like EclipseTabDockAction on CActions as well.
[/li][li]- API: The new TabMerger allows StackDockStations to be dropped on and merged with Dockables with one tab (like in the EclipseTheme).
[/li][li]- Bugfix: Text and Icons are now set for invisible tabs as well, thus the LayoutManager can now correctly guess the preferred size of the tabs.
[/li][li]- API: New DockTitleEvent „ActionsDockTitleEvent“ informs a DockTitle about the actions it should display, most of the built in DockTitles will support this feature
[/li][li]- API: New DockActionDistributor interface allows clients to define where actions apper (on a title, on a tab or on a info component).
[/li][li]- API: BasicDockableDisplayer/BasicDockableDisplayerDecorator now create a DockActionSource and forward this source to the DockTitle. That way the dislpayer/decorator can apply a filter to the actions.
[/li][li]- API: BubbleTheme now allows clients to show actions on tabs and on an info component, see the new BubbleTheme.ACTION_DISTRIBUTOR property.
[/li][li]- API: FlatTheme now allows clients to show actions on tabs and on an info component, see the new FlatTheme.ACTION_DISTRIBUTOR property.
[/li][li]- Bugfix: The framework should now also handle the NimbusLookAndFeel (whose package was renamed, so much for backwards compatibility…) under Java 7
[/li][li]- API: Added some additional interfaces to prevent constructors like „<A extends SimpleButtonDockAction & CommonDockable>“, as these constructors are not working well together with the compiler.
[/li][/ul]

Version 1.1.1p4
[ul]
[li]- Bugfix: DockElementRepresentative.shouldTransfersFocus is now respected by the DefaultFocusStrategy, meaning that clicking on an element like a tab now forwards the focus directly into a Dockable.
[/li][li]- API: Focus ownership is now transfered more aggressively: focus transfer can be delayed up to 200 milliseconds after the user clicked the mouse.
[/li][li]! API: FocusStrategy now receives a FocusStrategyRequest instead of several parameters.
[/li][/ul]

Version 1.1.1p5

Finally almost all TODOs have been done (the one concerning multi screen support is missing because of me missing a second screen). Also the point “1.1.1p4: Allow clients more control over transparency.” has been completed. The next step is an update for the EclipseTheme (don’t know how much work that is), afterwards version 1.1.1 is finished.

[ul]
[li] ! API: DropDownMiniButton.setDropDownIconColor removed, this color can now be configured throught the ColorManager and the key “action.dropdown.arrow”
[/li][li] - API: The icon can now be replaced through the IconManager using the key DropDownIcon.ICON_KEY
[/li][li] - API: The default icon resizes itself according to IconManager.MINIMUM_ICON_SIZE
[/li][li] ! API: The FocusStrategy can now decide whether a Dockable that was drag&dropped should keep its focus. The default implementation allows a Dockable to lose the focus if its new parent is a FlapDockStation (when it was “minimized”).
[/li][li] - Bugfix: MultipleCDockables on non-root working stations no longer lead to exceptions
[/li][li] - Bugfix: Non-root CStations are now correctly identified as CStations and not as SingleCDockables (which they are as well, but being a CStation is a more important attribute).
[/li][li] ! API: CPerspective.add/getRoot was renamed to add/getStation as “root” was a misleading name. The items consisted and are consisting of all CStations of a CControl, including nested stations.
[/li][li] - API: CControlPerspective allows now to read/write “entry” (partial) and “non-entry” (full) layouts.
[/li][li] ! API: MissingPerspectiveStrategy.createRoot renamed to createStation because the method can create any kind of station, not just root stations.
[/li][li] - Bugfix: UIProperties.put could throw a NullPointerException if no UIScheme was set
[/li][li] ! API: CDockable.getControl now returns a CControl
[/li][li] - API: New interface “CStationContainer” is an abstraction of Components that show a set of CStations, like for example the CContentArea. This interface allows the framework to be more general and there is no need to assume any set of CStations is a CContentArea.
[/li][li] - API: CControl does now a sanity check for unique identifiers, an identifier must not be null and contain at least one sign that is not a whitespace
[/li][li] - API: The size of ScreenDockWindows is now limited to the size of the biggest screen device, the exact behavior can be modified by implementing a new BoundaryRestriction
[/li][li] - Bugfix: SingleParentRemover now also can remove DockStations that were just added into the tree (meaning, invalid stations will no longer show up).
[/li][li] ! API: CDockable.isMinimizeHold/isMinimizeHoldSwitchable renamed in isSticky/isStickySwitchable. “sticky” is a much better name for a property than “minimizeHold”.
[/li][li] - API: SplitDockPerspective now supports reading and writing PlaceholderMaps, just like SplitDockStation
[/li][li] ! API: All “Secure”-classes, needed to support unsigned applets, have been removed (they were already deprecated and the documentation clearly stated, that they will be removed). The property DockController.set/getSecureEnvironment is to be used instead of the secure-classes.
[/li][li] - API: Clients can tell BackgroundComponents to be transparent or to be solid by calling BackgroundComponent.setTransparency. There is no alpha value, a component either paints its background or it does not.
[/li][/ul]

Version 1.1.1p5a

Just a bugfix.

[ul]
[li] - Bugfix/API: New CommonDockStationFactory and CommonDockStationLayout are used to persistently store the layout of CStations. This new facillity allows clients to dynamically create new root-CStations that are also SingleCDockables while loading a layout.
[/li][li] ! API: CommonDockStation has a new method “getConverterID” which tells what DockFactory to use for reading and writing the layout
[/li][/ul]

Version 1.1.1p5b
Yet again only bugfixes. But since the summer ended today in endless rain :frowning: , I might do more work in the next few months. :slight_smile:

[ul]
[li] - Bugfix: FlapDockStation did create a drag&drop operation even if it already knew that the operation was invalid, as a result an Exception was thrown later.
[/li][li] - Bugfix: CGroupBehaviors no longer forwards actions to DockStations if these DockStations do not support the action.
[/li][li] ! API: The property telling whether the user can see a Dockable is now called „showing“ and no longer „dockable-visible“. This should prevent more confusion about „visibility“ vs „true visibility“ (the later term is no longer to be used, its now „showing“).
[/li][li] - API: The new property SplitDockStation.DIVIDER_STRATEGY and the interface SplitDividerStrategy allow a client to specify a custom algorithm for resizing the children of a SplitDockStation
[/li][li] - Bugfix/API: Yet another update to the focus system: focus is now handled by „FocusRequest“ objects. One request wins, the others get canceled. The system refuses to grant focus to an invalid component (e.g. one that is not visible) if there are still requests pending.
[/li][/ul]

Version 1.1.1p5c

Added better support for applications with more than one JFrame.

I also had a look at Eclipse 4.2. There are not many changes needed in the framework to support a similar look and feel. Some new colors, some new hover effects… but I will not implement the random flickering I got. :wink: Also the current theme from Eclipse 3 will remain available. Since I do not like the new look of Eclipse, I even think of letting the old look remain as default.

[ul]
[li] - API: DockRelocator offers a method „cancel“ to cancel any DnD operation at any time.
[/li][li] - API: ScreenDockWindow now closes and reopens its ScreenDockWindows if the owner window (the root window) changed. This way the windows stay open if the client switches to a new root frame.
[/li][li] ! API: In order to prevent focus stealing ScreenDockWindow has a new method „setPreventFocusStealing“. This method is only used if the root window changed. Focus stealing prevention is unset after ScreenDockStation.PREVENT_FOCUS_STEALING_DELAY milliseconds.
[/li][li] - API: New CStationContainerHistoryRewriter tries to ensure that a CDockable stays on the same CStationContainer as long as possible.
[/li][li] - Bugfix: A removed MultipleCDockable did not forget its unique identifier, when adding it again this caused an exception if another dockable got that unique id.
[/li][li] - Bugfix: The location of a removed CDockable could be forgotten even if CControl.shoudStore returned true.
[/li][/ul]

Version 1.1.1p6

A minor update, includes nothing that clients will see immediately (meaning: for most people there is no reason to upgrade from 1.1.1p5c).

DockStation got a „layering mechanism“, which means that the code for drag&drop is now much cleaner and easier to understand. Several interfaces were modified a bit in order to support this new mechanism. The behavior during drag&drop of some stations (i.e. ScreenDockStation) changed a bit, hopefully making more sense now.

If you are wondering what I’m actually doing: in the past month Hervé Guillaume and I were implementing a new toolbar extension. Once finished the framework will offer toolbars which behave much the same way as the toolbars from Photoshop. Since the toolbars and the Dockables share the same API, interesting effects like dragging a toolbar-button to the main-panel, and extending the button to a much larger panel with more information, will at least be possible (although not necessarily implemented :wink: ).

[ul]
[li] - API: New GlobalMouseDispatcher collects and distributes MouseEvents. Can be used by clients to listen to events.
[/li][li] ! API: The „check“ methods of MouseFocusObserver have been removed
[/li][li] ! API: Creating a DockableDisplayer now requires the use of a DisplayerRequest. Instead of just one possibility to replace the factory creating DockableDisplayers, clients and extensions have now several possiblities, e.g. directly in a Dockable or in a DockStation
[/li][li] ! API: During a drag and drop operation a DockStation now appears to consist of many layers instead of only one layer. This allows more complex rules to find the target of a drop operation. The new layers are described by the interface „DockStationDropLevel“, the concept of the „override zone“ has been completely replaced by this new layer mechanism.
[/li][li] - Bugfix: SplitDockStation did ignore the DockAcceptance in certain situations
[/li][li] - Bugfix: VetoableDockRelocatorListener.searched is now actually called
[/li][li] - API: Workarounds-API is now public, clients can register custom workarounds (e.g. to resolve issues with JWebBrowser).
[/li][/ul]

Version 1.1.1p6a

Fixes some memory leaks.
[ul]
[li] - Bugfix: Memory Leak in FlatTab, listener was added twice
[/li][li] - Bugfix: Memory Leaf in RoundRectButton, listener was not removed properly
[/li][li] - Bugfix: SplitDockStation did not fire dockable removing eveng if the method “dropOver” was called
[/li][li] - API: CControl offers the new method “getFocusedCDockable”, which returns the currently focused CDockable or null
[/li][li] - API: Added DockFrontend.deleteAll, which quickly deletes all settings of the frontend.
[/li][li] ! API: DockFrontend.readXml/read now deletes the existing settings, this is how most developers would expect the method to work.
[/li][/ul]

Version 1.1.1p6b

Some more little changes. Most of my time still is devoted to the toolbar project. It’s realistic to say, that we finish the toolbar extension within the next month.

[ul]
[li] API: The new interface DockActionImportanceOrder allows to define which actions are the most important actions, if there is not enough space to show all actions the most important actions stay visible a bit longer
[/li][li] API: If tabs and actions are shown, tabs are now hidden before actions are hidden
[/li][li] Bugfix: When setting the location of a Dockable “d”, such that a SplitDockStation with a maximixed child needs to de-maximize its child, and if that child is a StackDockStation containing “d”, and all of this is executed by a CSplitDockStationHandle: then remove “d” from its parent before resizing. Because this way the EventQueue is cleaned before AWTEvents regarding “d” are sent, allowing new Component-resize events to be actually delivered.
[/li][li] Bugfix: Removing a DockAction from a submenu did not have any effect unless the submenu was rebuilt.
[/li][li] Bugfix: A nested DropDownAction could lead to a NPE during “unbind”.
[/li][li] Bugfix/API: merged changes of Thomas. SplitDockStation should clean up wrong mouse cursor now. Improvements in the Glass-Extension.
[/li][/ul]

Version 1.1.1p6c

Minor adjustements, most of them necessary for the Toolbar extension (which is one a good way).

It’s now possible to show text on mini-buttons (the buttons that show DockActions/CActions). Clients using Common can just call “CDecorateableAction.setShowTextOnButton”. The buttons also support customization like setting a font or changing colors.

[ul]
[li] - Bugfix: Mainfest of “Common Layout” example was wrong.
[/li][li] - Bugfix: Moving a Dockable over itself on a SplitDockStation now results in a no-op instead of moving the Dockable to the ScreenDockStation.
[/li][li] - Bugfix: Using the keyboard to change the expanded-state of a CDockable no longer prints a warning about “subclasses of DockHierarchyListener should not modify hierarchy”.
[/li][li] - Bugfix: Drop behavior of SplitDockStation acted rather strangely if the mouse was outside the station. Found by Herve.
[/li][li] ! API: Simplified BasicDockableDisplayer by removing a few methods, added the “createContentPane” method.
[/li][li] - API: TabDecorator now makes use of TabContentFilter, and updates its content if the Dockable changes its title or icon
[/li][li] - API: The EclipseDockableDisplayer2 replaces EclipseDockableDisplayer, it is based on BasicDockableDisplayer - like all the other displayers.
[/li][li] - API: BasicDockableDisplayer can now show the title above the decorator
[/li][li] ! API: Generics now force CStations to use CommonDockStation as internal representations
[/li][li] - Bugfix: when maximizing a CDockable, the CMaximizedMode tries to ensure that the dockable remains in the same CStationContainer
[/li][li] - Bugfix: not all drop down buttons did support the disabled arrow icon
[/li][li] - API: It is now possible to show text on buttons for DockActions. The buttons also support different fonts and colors. Whether text shows up is decided by the ButtonContentFilter.
[/li][/ul]

I missed Version 1.1.1p6d :eek:

Version 1.1.1p6e
Some smaller bugfixes.

You may have noticed that currently I do not invest much time in the framework. But starting next month I have a longer period of unpaid vacation. One of the things I really want to do is to finally rush the Toolbar Extension to its first official release. I think it’s realistic to say, that Toolbars will be available at the middle or end of March.

[ul]
[li] - API: If GlassedPane creates a tooltip it calls the “createTooltip” method of the JComponent where the mouse hovers over. Clients can set a custom strategy called “ToolbarStrategy” to manage tooltips.
[/li][li] - Bugfix: When changing the layout (setting of a DockFrontend), protected root stations were unregistered. They should have been unaffected by the change.
[/li][li] - API: ButtonDropDownHandler and related classes can now handle a “null” component as view. This allows an action to show up on a drop down button even if it does not show up in its menu.
[/li][li] - API: New enum “IconHandling”. If a client sets a null icon at a DefaultDockable, DefaultSingleCDockable or DefaultMultipleCDockable the icon is not shown. If the client does not set an icon, the default icon is shown. The IconHandling allows clients to specify exactly whether “null” means “no icon” or “default icon”.
[/li][li] - Bugfix: MenuMenuHandler now also supports a “null” component as view, keeping the behavior consistent with ButtonDropDownHandler.
[/li][li] - Bugfix: CFlapLayoutManager confused “width” and “height”
[/li][/ul]

Version 1.1.1p6f

Fixing one memory leak

Version 1.1.1p7

Added the “DisablingStrategy” and some code to handle disabled items. Now you can disabled actions, titles and tabs.

[ul]
[li] - API: The DisablingStrategy allows to globally disable items like actions or titles
[/li][li] - API: All DockActions can now be disabled by the DisablingStrategy
[/li][li] ! API: AbstractDockTitle has a new method “setDisabled”, it is used to support the DisablingStrategy
[/li][li] ! API: All tabs can now be disabled by the DisablingStrategy
[/li][li] - API: SplitDockStation and FlapDockStation will react on the DisablingStrategy as well
[/li][li] - API: CDockable has a new method “setEnabled” with which parts of the Dockable can be stopped
[/li][/ul]

Version 1.1.1p7a

Bugfixes…

[ul]
[li] - Bugfix: OverpaintablePanel now correctly implements getMinimum/Preferred/MaximumSize.
[/li][li] - Bugfix: RootMenuPiece unbinds itself now with some delay, allowing the attached ActionListeners to complete their work
[/li][li] - API: The minimum size for Dockables on a SplitDockStation has been redesigned. Only the minimum size of Components has a real influence now, tabs and titles are most times ignored.
[/li][/ul]

Version 1.1.1p7b

For a change some interesting new features.

  • The “span” mechanism adds some animations: if you are about to drop a Dockable, the station beneath it may decide to visually open a space for it. If you want to customize (or disable) the feature, use the property-key “DockTheme.SPAN_FACTORY” to set a new factory for the spans. Have a look at the existing implementations to learn how it works.
    This feature is not enabled for the EclipseTheme, because Eclipse does not have such a feature either.

  • You remember how tedious it is to open a new Dockable at a good spot? The new method “CWorkingArea.show” can help, as it opens a Dockable at an “optimal spot”, in this case the “optimal spot” is right beside the last focused Dockable. The entire history of focused Dockables is now recorded in the “FocusHistory”, which can be accessed through “DockController.getFocusHistory”.

[ul]
[li] ! API: All DockStation can now draw some indicators when a dockable is dragged from them. Only BasicDockTheme and FlatDockTheme do actually draw these markings, BubbleDockTheme and EclipseDockTheme completely ignore them.
[/li][li] - API: The new “span” mechanism allows animations when dropping a Dockable.
[/li][li] - API: An empty FlapDockStation now has a preferred size of 0/0, but when the mouse is near the station its preferred size increases
[/li][li] ! API: DockStation.prepareDrop and associated methods receive now a StationDropItem instead of several parameters. This allows to forward more information to these methods, and will be more backwards compatible for future changes.
[/li][li] - API: Making a SplitDockStation very small, such that dividers become invalid, no longer changes the valud of dividers forever.
[/li][li] - API: SplitDockStation now suppors “Span” as well.
[/li][li] - Bugfix: When multiple listeners are receiving Key- and DoubleClick-Events, the the listeners further down the tree are invoked first.
[/li][li] - API: New FocusHistory keeps track of the order of focused Dockables, can be accessed through DockController.getFocusHistory
[/li][li] - API: CControl will transfer the focus from minimized Dockables to not minimized Dockables
[/li][li] - API: CWorkingArea offers the new method “show” which show a Dockable at the “optimal spot”
[/li][/ul]