edu.rice.cs.util.docnavigation
Class JListSortNavigator<ItemT extends INavigatorItem>

java.lang.Object
  extended by 
      extended by edu.rice.cs.util.docnavigation.JListNavigator<ItemT>
          extended by edu.rice.cs.util.docnavigation.JListSortNavigator<ItemT>
All Implemented Interfaces:
IAWTContainerNavigatorActor, IDocumentNavigator<ItemT>, DropTargetListener, EventListener

 class JListSortNavigator<ItemT extends INavigatorItem>
extends JListNavigator<ItemT>
implements DropTargetListener


Field Summary
(package private)  DropTarget dropTarget
          Drag and drop target.
 
Fields inherited from class edu.rice.cs.util.docnavigation.JListNavigator
_model
 
Fields inherited from interface edu.rice.cs.util.docnavigation.IDocumentNavigator
MODEL_INITIATED_PROPERTY_NAME
 
Constructor Summary
JListSortNavigator()
           
 
Method Summary
 void addDocument(ItemT doc)
          Adds the document to the list.
 void dragEnter(DropTargetDragEvent dropTargetDragEvent)
          User dragged something into the component.
 void dragExit(DropTargetEvent dropTargetEvent)
           
 void dragOver(DropTargetDragEvent dropTargetDragEvent)
           
 void drop(DropTargetDropEvent dropTargetDropEvent)
          User dropped something on the component.
 void dropActionChanged(DropTargetDragEvent dropTargetDragEvent)
           
private  int insertDoc(ItemT doc)
          Inserts the document into its sorted position.
 String toString()
           
 
Methods inherited from class edu.rice.cs.util.docnavigation.JListNavigator
addDocument, addNavigationListener, addTopLevelGroup, asContainer, clear, contains, execute, getCurrent, getDocumentCount, getDocuments, getDocumentSelectedCount, getDocumentsInBin, getFirst, getFromModel, getGroupSelectedCount, getLast, getModelLock, getNamesOfSelectedTopLevelGroup, getNavigatorListeners, getNext, getPrevious, getRenderer, getSelectedDocuments, getSelectedFolders, getSelectionCount, isDocumentSelected, isEmpty, isGroupSelected, isNextChangeModelInitiated, isRootSelected, isSelectedAt, isSelectedInGroup, isTopLevelGroupSelected, refreshDocument, removeDocument, removeNavigationListener, requestSelectionUpdate, selectDocument, selectDocumentAt, setNextChangeModelInitiated
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface edu.rice.cs.util.docnavigation.IDocumentNavigator
addDocument, addDocument, addFocusListener, addNavigationListener, addTopLevelGroup, contains, execute, getFocusListeners, getNext, getPrevious, isSelectedInGroup, refreshDocument, removeDocument, removeFocusListener, removeNavigationListener, repaint, requestSelectionUpdate, selectDocument
 

Field Detail

dropTarget

DropTarget dropTarget
Drag and drop target.

Constructor Detail

JListSortNavigator

JListSortNavigator()
Method Detail

addDocument

public void addDocument(ItemT doc)
Adds the document to the list. Should only be executed from event thread.

Overrides:
addDocument in class JListNavigator<ItemT extends INavigatorItem>
Parameters:
doc - the document to add

insertDoc

private int insertDoc(ItemT doc)
Inserts the document into its sorted position. Should only be executed in the event thread.

Parameters:
doc - the document to add

toString

public String toString()
Overrides:
toString in class JListNavigator<ItemT extends INavigatorItem>

dragEnter

public void dragEnter(DropTargetDragEvent dropTargetDragEvent)
User dragged something into the component.

Specified by:
dragEnter in interface DropTargetListener

dragExit

public void dragExit(DropTargetEvent dropTargetEvent)
Specified by:
dragExit in interface DropTargetListener

dragOver

public void dragOver(DropTargetDragEvent dropTargetDragEvent)
Specified by:
dragOver in interface DropTargetListener

dropActionChanged

public void dropActionChanged(DropTargetDragEvent dropTargetDragEvent)
Specified by:
dropActionChanged in interface DropTargetListener

drop

public void drop(DropTargetDropEvent dropTargetDropEvent)
User dropped something on the component. Only runs in event thread.

Specified by:
drop in interface DropTargetListener