|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JList
org.ceryle.ui.CollectionList
public class CollectionList
Extends JList to encapsulate drag and drop functionality and rendering for the DocumentView's collection list.
Note that if the System property
XNodeStoreImpl.SAFE_OVERWRITE_MODE
("xnode-database-safe-overwrite-mode") is set true,
drag-and-drop overwriting of existing XNodes will fail. The
default value for this property is false (unset).
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class javax.swing.JList |
|---|
JList.AccessibleJList |
| Nested classes/interfaces inherited from class javax.swing.JComponent |
|---|
JComponent.AccessibleJComponent |
| Nested classes/interfaces inherited from class java.awt.Container |
|---|
Container.AccessibleAWTContainer |
| Nested classes/interfaces inherited from class java.awt.Component |
|---|
Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy |
| Field Summary | |
|---|---|
protected MouseInputListener |
m_dragListener
|
| Fields inherited from class javax.swing.JList |
|---|
HORIZONTAL_WRAP, VERTICAL, VERTICAL_WRAP |
| Fields inherited from class javax.swing.JComponent |
|---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Component |
|---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
|---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
|---|---|
CollectionList(DocumentView docview)
Constructor for a collection list with its parent DocumentView. |
|
| Method Summary | |
|---|---|
protected boolean |
acceptDroppedString(String s,
DropTargetDropEvent e)
Receive a drag and dropped String, returning true if accepted at the given Point. |
protected void |
fireSelectionValueChanged(int firstIndex,
int lastIndex,
boolean isAdjusting)
Override the method to also update the view. |
int |
getItemCount()
Returns the number of items in the collection list. |
List |
getList()
This supplements the superclass' getModel() by returning the backing model as a List (rather than a ListModel). |
boolean |
getShowTitles()
Returns the mode for either showing titles (true) or IDs (false). |
void |
handleMouseMotionEvent(DropTargetDragEvent dtde,
MouseEvent me)
Processes mouse motion dragged or moved events from the ExtendedMouseMotionListener, passing them on to the superclass method unless the current mouse position is within the Vernier. |
protected void |
refresh()
Refreshes the collection list display. |
void |
setCollectionTitle(String title)
Sets the title of the current Collection to title. |
void |
setModel(ListModel model)
Overrides the superclass to fail upon setting anything other than a SetModel. |
void |
setShowTitles(boolean showTitles)
Sets the mode for either showing titles (true) or IDs (false). |
void |
setValueIsAdjusting(boolean b)
Suppress attempts to set false prior to initialization. |
void |
sort()
Sorts the collection list. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected MouseInputListener m_dragListener
| Constructor Detail |
|---|
public CollectionList(DocumentView docview)
| Method Detail |
|---|
protected void fireSelectionValueChanged(int firstIndex,
int lastIndex,
boolean isAdjusting)
fireSelectionValueChanged in class JListpublic void setValueIsAdjusting(boolean b)
setValueIsAdjusting in class JList
protected boolean acceptDroppedString(String s,
DropTargetDropEvent e)
public void handleMouseMotionEvent(DropTargetDragEvent dtde,
MouseEvent me)
public boolean getShowTitles()
public void setShowTitles(boolean showTitles)
public void setCollectionTitle(String title)
public List getList()
public void setModel(ListModel model)
setModel in class JListRuntimeException - if the parameter is not a SetModelpublic int getItemCount()
protected void refresh()
public void sort()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||