The JTree is coming along really well.

Some other issues:
- if a directory node is selected, and you press the left arrow key, the
control icon collapses, but the directory does not. I am not sure if it
should, but it should be consistant with the icon.
- Clicking on nodes does not work after using the arrow keys to
expand/collapse nodes.
- If a child node of a directory is selected, and the left arrow key is
pressed, then the directory collapses. I think this is wrong... it
should expand/collapse when a parent node is selected, not the child.
- When a parent is expanded/collapsed using the arrow keys, then the
first child is selected. This is wrong, the parent should remain
highlighted.
- The left/right arrow keys on the root node do not work properly. The
control icons collapse/expand, but the actual children of the parent
remain in the same state (expanded if they were expanded before the key
presses).

etc... There seems to be a lot of inconsistencies with the key
pressing/painting of the tree. You need to be sure that mouse clicks
still work if the arrow keys are pressed. 

TreeTraverseAction should handle the left/right keys. You might want to
look into this function as well as the updating of the tree when these
keys are pressed.

Thanks,
Lillian


On Wed, 2006-04-26 at 14:28 +0200, Audrius Meskauskas wrote:
> This path makes the view and navigation rules during the multiple tree 
> selection closer to Sun's.
> 
> 2006-04-26  Audrius Meskauskas  <[EMAIL PROTECTED]>
> 
>     * javax/swing/JTree.java (setLeadSelectionPath):
>     Repaint the new and old lead pathes.
>     * javax/swing/plaf/basic/BasicTreeUI.java
>     (FocusHandler): Repaint the lead row when focus changes.
>     (PropertyChangeHandler): Use existing constants, not the
>     string literals for the property names.
>     (TreeIncrementAction): Shrink the selection when moving
>     from the selection edge to the selection anchor.
>     (TreeSelectionHandler.valueChanged): Repaint the
>     new and old lead pathes.
>     (paintRow): Treat row as focused only if it is the lead row.
>     * javax/swing/tree/DefaultTreeCellRenderer.java
>     (getTreeCellRendererComponent): Set the vertical alignment to CENTER.
>     (paint): Rewritten.
>     * javax/swing/tree/DefaultTreeSelectionModel.java
>     (addSelectionPath): Event construction fix (old and new lead were
>     always the same).
>     (addSelectionPaths): Likewise.
>     * javax/swing/JComponent.java (setOpaque): Explained.
>     * javax/swing/tree/FixedHeightLayoutCache.java (getBounds):
>     Accept null.
>     * javax/swing/tree/VariableHeightLayoutCache.java (getBounds):
>     Accept null.


Reply via email to