/** * Creates a new EditCursorLabelAction.EditCursorDialog instance. */ public EditCursorDialog( final Window aParent, final Cursor aCursor ) { super( aParent, ModalityType.APPLICATION_MODAL ); setResizable( false ); this.defaultLabel = aCursor.getLabel(); this.defaultColor = aCursor.getColor(); initDialog( aCursor ); }
this.labelEditor = new JTextField( aCursor.getLabel(), 10 );
/** * Creates a new Cursor instance a copy of a given cursor. * * @param aCursor * the cursor to copy, cannot be <code>null</code>. * @param aAbsLen * the absolute length of the data, >= 0L. * @throws IllegalArgumentException * in case the given index was invalid. */ public CursorImpl( final Cursor aCursor, final long aAbsLen ) { this( aCursor.getIndex() ); this.color = aCursor.getColor(); this.label = aCursor.getLabel(); this.timestamp = aCursor.isDefined() && ( aCursor.getTimestamp() <= aAbsLen ) // ? Long.valueOf( aCursor.getTimestamp() ) : null; }
String label = aCursor.getLabel(); if ( !aCursor.hasLabel() )
if ( cursor.hasLabel() ) label = label.concat( ", " ).concat( cursor.getLabel() );