/** * Gets a path describing this location in terms of the * DockingFrames. The method is ignoring any children of this location. * @return the path to this location or <code>null</code> */ public DockableProperty findProperty(){ return findProperty( null ); }
/** * Gets a path describing this location in terms of the * DockingFrames. The method is ignoring any children of this location. * @return the path to this location or <code>null</code> */ public DockableProperty findProperty(){ return findProperty( null ); }
@Override public DockableProperty findProperty( DockableProperty successor ) { if( successor == null ){ successor = new SplitDockProperty( 0, 0, 1, 1 ); } if( parent != null ){ return parent.findProperty( successor ); } return successor; }
@Override public DockableProperty findProperty( DockableProperty successor ) { if( successor == null ){ successor = new FlapDockProperty( Integer.MAX_VALUE ); } if( parent != null ){ return parent.findProperty( successor ); } return successor; }
@Override public DockableProperty findProperty( DockableProperty successor ) { if( successor == null ){ successor = new FlapDockProperty( Integer.MAX_VALUE ); } if( parent != null ){ return parent.findProperty( successor ); } return successor; }
@Override public DockableProperty findProperty( DockableProperty successor ) { if( successor == null ){ successor = new SplitDockProperty( 0, 0, 1, 1 ); } if( parent != null ){ return parent.findProperty( successor ); } return successor; }
@Override public DockableProperty findProperty( DockableProperty successor ){ ScreenDockProperty screen = new ScreenDockProperty( x, y, width, height ); screen.setSuccessor( successor ); if( parent != null ){ return parent.findProperty( screen ); } return screen; }
@Override public int hashCode(){ Object root = findRoot(); Object mode = findMode(); Object property = findProperty(); int result = 0; if( root != null ){ result = root.hashCode(); } result *= 31; if( mode != null ){ result += mode.hashCode(); } result *= 31; if( property != null ){ result += property.hashCode(); } return result; } }
@Override public DockableProperty findProperty( DockableProperty successor ){ ScreenDockProperty screen = new ScreenDockProperty( x, y, width, height ); screen.setSuccessor( successor ); if( parent != null ){ return parent.findProperty( screen ); } return screen; }
@Override public DockableProperty findProperty( DockableProperty successor ){ StackDockProperty stack = new StackDockProperty( index ); stack.setSuccessor( successor ); return parent.findProperty( stack ); }
@Override public int hashCode(){ Object root = findRoot(); Object mode = findMode(); Object property = findProperty(); int result = 0; if( root != null ){ result = root.hashCode(); } result *= 31; if( mode != null ){ result += mode.hashCode(); } result *= 31; if( property != null ){ result += property.hashCode(); } return result; } }
@Override public DockableProperty findProperty( DockableProperty successor ){ StackDockProperty stack = new StackDockProperty( index ); stack.setSuccessor( successor ); return parent.findProperty( stack ); }
@Override public DockableProperty findProperty( DockableProperty successor ){ SplitDockFullScreenProperty property = new SplitDockFullScreenProperty(); property.setSuccessor( successor ); CLocation parent = getParent(); if( parent != null ){ return parent.findProperty( property ); } return property; }
@Override public DockableProperty findProperty( DockableProperty successor ){ SplitDockFullScreenProperty property = new SplitDockFullScreenProperty(); property.setSuccessor( successor ); CLocation parent = getParent(); if( parent != null ){ return parent.findProperty( property ); } return property; }
@Override public boolean equals( Object obj ){ if( obj instanceof CLocation ){ CLocation that = (CLocation)obj; return equals( findRoot(), that.findRoot() ) && equals( findMode(), that.findMode() ) && equals( findProperty(), that.findProperty() ); } return false; }
@Override public boolean equals( Object obj ){ if( obj instanceof CLocation ){ CLocation that = (CLocation)obj; return equals( findRoot(), that.findRoot() ) && equals( findMode(), that.findMode() ) && equals( findProperty(), that.findProperty() ); } return false; }
@Override public DockableProperty findProperty( DockableProperty successor ){ ScreenDockProperty screen = new ScreenDockProperty( getX(), getY(), getWidth(), getHeight(), null, true ); screen.setSuccessor( successor ); CLocation parent = getParent(); if( parent != null ){ return parent.findProperty( screen ); } return screen; }
throw new IllegalArgumentException( "the location is not sufficient to find the root station" ); DockableProperty property = location.findProperty(); if( property == null ) throw new IllegalArgumentException( "the location does not carry enough information to find the location of dockable" );
@Override public DockableProperty findProperty( DockableProperty successor ){ ScreenDockProperty screen = new ScreenDockProperty( getX(), getY(), getWidth(), getHeight(), null, true ); screen.setSuccessor( successor ); CLocation parent = getParent(); if( parent != null ){ return parent.findProperty( screen ); } return screen; }
setProperties( newMode, dockable, new Location( mode.getModeIdentifier(), root, location.findProperty() ) ); apply( dockable, newMode, true );