public static DockableState fixVLDockingBug ( DockingDesktop dockingDesktop , Dockable dockable ) { Assert . notNull ( dockingDesktop , "dockingDesktop" ) ; Assert . notNull ( dockable , "dockable" ) ; final DockingContext dockingContext = dockingDesktop . getContext ( ) ; final DockKey dockKey = dockable . getDockKey ( ) ; DockableState dockableState = dockingDesktop . getDockableState ( dockable ) ; final Boolean thisFixApplies = ( dockingContext . getDockableByKey ( dockKey . getKey ( ) ) != null ) ; if ( ( thisFixApplies ) && ( dockableState == null ) ) { dockingDesktop . registerDockable ( dockable ) ; dockableState = dockingDesktop . getDockableState ( dockable ) ; // dockKey.setLocation(dockableState.getLocation()); Assert . notNull ( dockableState , "dockableState" ) ; } return dockableState ; }
Fixes an VLDocking bug consisting on dockables that belong to a docking desktop have no state on it .