|
Java™ Platform Standard Ed. 6 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.swing.plaf.ComponentUI
javax.swing.plaf.TreeUI
javax.swing.plaf.basic.BasicTreeUI
public class BasicTreeUI
The basic L&F for a hierarchical data structure.
| Nested Class Summary | |
|---|---|
class |
BasicTreeUI.CellEditorHandler
Listener responsible for getting cell editing events and updating the tree accordingly. |
class |
BasicTreeUI.ComponentHandler
Updates the preferred size when scrolling (if necessary). |
class |
BasicTreeUI.FocusHandler
Repaints the lead selection row when focus is lost/gained. |
class |
BasicTreeUI.KeyHandler
This is used to get mutliple key down events to appropriately generate events. |
class |
BasicTreeUI.MouseHandler
TreeMouseListener is responsible for updating the selection based on mouse events. |
class |
BasicTreeUI.MouseInputHandler
MouseInputHandler handles passing all mouse events, including mouse motion events, until the mouse is released to the destination it is constructed with. |
class |
BasicTreeUI.NodeDimensionsHandler
Class responsible for getting size of node, method is forwarded to BasicTreeUI method. |
class |
BasicTreeUI.PropertyChangeHandler
PropertyChangeListener for the tree. |
class |
BasicTreeUI.SelectionModelPropertyChangeHandler
Listener on the TreeSelectionModel, resets the row selection if any of the properties of the model change. |
class |
BasicTreeUI.TreeCancelEditingAction
ActionListener that invokes cancelEditing when action performed. |
class |
BasicTreeUI.TreeExpansionHandler
Updates the TreeState in response to nodes expanding/collapsing. |
class |
BasicTreeUI.TreeHomeAction
TreeHomeAction is used to handle end/home actions. |
class |
BasicTreeUI.TreeIncrementAction
TreeIncrementAction is used to handle up/down actions. |
class |
BasicTreeUI.TreeModelHandler
Forwards all TreeModel events to the TreeState. |
class |
BasicTreeUI.TreePageAction
TreePageAction handles page up and page down events. |
class |
BasicTreeUI.TreeSelectionHandler
Listens for changes in the selection model and updates the display accordingly. |
class |
BasicTreeUI.TreeToggleAction
For the first selected row expandedness will be toggled. |
class |
BasicTreeUI.TreeTraverseAction
TreeTraverseAction is the action used for left/right keys. |
| Field Summary | |
|---|---|
protected TreeCellEditor |
cellEditor
Editor for the tree. |
protected Icon |
collapsedIcon
|
protected boolean |
createdCellEditor
Set to true if editor that is currently in the tree was created by this instance. |
protected boolean |
createdRenderer
Set to true if the renderer that is currently in the tree was created by this instance. |
protected TreeCellRenderer |
currentCellRenderer
Renderer that is being used to do the actual cell drawing. |
protected int |
depthOffset
How much the depth should be offset to properly calculate x locations. |
protected Hashtable<TreePath,Boolean> |
drawingCache
Used for minimizing the drawing of vertical lines. |
protected Component |
editingComponent
When editing, this will be the Component that is doing the actual editing. |
protected TreePath |
editingPath
Path that is being edited. |
protected int |
editingRow
Row that is being edited. |
protected boolean |
editorHasDifferentSize
Set to true if the editor has a different size than the renderer. |
protected Icon |
expandedIcon
|
protected boolean |
largeModel
True if doing optimizations for a largeModel. |
protected int |
lastSelectedRow
Index of the row that was last selected. |
protected int |
leftChildIndent
Distance between left margin and where vertical dashes will be drawn. |
protected AbstractLayoutCache.NodeDimensions |
nodeDimensions
Reponsible for telling the TreeState the size needed for a node. |
protected Dimension |
preferredMinSize
Minimum preferred size. |
protected Dimension |
preferredSize
Size needed to completely display all the nodes. |
protected CellRendererPane |
rendererPane
Used to paint the TreeCellRenderer. |
protected int |
rightChildIndent
Distance to add to leftChildIndent to determine where cell contents will be drawn. |
protected boolean |
stopEditingInCompleteEditing
Set to false when editing and shouldSelectCell() returns true meaning the node should be selected before editing, used in completeEditing. |
protected int |
totalChildIndent
Total distance that will be indented. |
protected JTree |
tree
Component that we're going to be drawing into. |
protected TreeModel |
treeModel
Used to determine what to display. |
protected TreeSelectionModel |
treeSelectionModel
Model maintaing the selection. |
protected AbstractLayoutCache |
treeState
Object responsible for handling sizing and expanded issues. |
protected boolean |
validCachedPreferredSize
Is the preferredSize valid? |
| Constructor Summary | |
|---|---|
BasicTreeUI()
|
|
| Method Summary | |
|---|---|
void |
cancelEditing(JTree tree)
Cancels the current editing session. |
protected void |
checkForClickInExpandControl(TreePath path,
int mouseX,
int mouseY)
If the mouseX and mouseY are in the
expand/collapse region of the row, this will toggle
the row. |
protected void |
completeEditing()
Messages to stop the editing session. |
protected void |
completeEditing(boolean messageStop,
boolean messageCancel,
boolean messageTree)
Stops the editing session. |
protected void |
completeUIInstall()
Invoked from installUI after all the defaults/listeners have been installed. |
protected void |
completeUIUninstall()
|
protected void |
configureLayoutCache()
Resets the TreeState instance based on the tree we're providing the look and feel for. |
protected CellEditorListener |
createCellEditorListener()
Creates a listener to handle events from the current editor. |
protected CellRendererPane |
createCellRendererPane()
Returns the renderer pane that renderer components are placed in. |
protected | |