/** * Removes all children of this source. */ public void removeAll(){ int length = getDockActionCount(); if( !listeners.isEmpty() ){ for( SeparatorSource source : separators ){ source.removeDockActionSourceListener( listener ); } for( DockActionSource source : sources ){ source.removeDockActionSourceListener( listener ); } } separators.clear(); sources.clear(); if( length > 0 ){ fireRemoved( 0, length-1 ); } }