Opened 10 years ago

Closed 9 years ago

Last modified 9 years ago

#9953 closed defect (fixed)

Tree: two highlighted nodes upon mouse click and arrow keyboard move

Reported by: Jean-Rubin Leonard Owned by: bill
Priority: high Milestone: 1.5
Component: Dijit Version: 1.3.2
Keywords: tree onClick FocusNode Cc:
Blocked By: Blocking:

Description

currently when I click on a node with the mouse and then proceed to navigate away from that node with the keyboard, both the node i had clicked on and the one with the current focus are highlighted. This is counter intuitive as user expect the focus to move when using the keyboard to move around the tree and the highlighting to follow. This behavior can be reproduced in the dijit/tests/test_Tree.html so no test file is attached. JR

Change History (6)

comment:1 Changed 10 years ago by bill

Milestone: tbd1.5
Summary: Two highlighted nodes upon mouse click and arrow keyboard moveTree: two highlighted nodes upon mouse click and arrow keyboard move

comment:2 Changed 9 years ago by bill

Owner: set to bill
Status: newassigned

Yup, it's messed up now. Focus and selected should be independent, and the selected item should be controlled via the selectedItem or path attributes. Will fix along w/#8616.

comment:3 Changed 9 years ago by bill

Resolution: fixed
Status: assignedclosed

(In [21728]) Decouple concepts of "focused node" and "selected node", so that:

  1. A tree doesn't start with any node mark as selected; app needs to call attr("selectedItem", ...) or attr("path", ...). Fixes #8616.
  2. Using arrow keys to navigate in a Tree will not change the selected item. Fixes #9953.

I'm unclear what should happen when the user clicks a node (especially when clicking a branch node, which merely opens the node). For now, clicking a node does not select it.

!strict.

comment:4 Changed 9 years ago by bill

(In [21730]) Make clicking, double-clicking, or ENTER-keying a TreeNode select it. But clicking/double-clicking an expando node (plus sign) does not select the TreeNode. Still need to add tests. Refs #8616, #9953 !strict.

comment:5 Changed 9 years ago by bill

(In [21738]) Keyboard test case for TreeNode focus and selection. Tree still needs mouse tests written, currently there aren't any. Refs #8616, #9953 !strict.

comment:6 Changed 9 years ago by bill

(In [21739]) Keyboard test case for TreeNode focus and selection. Tree still needs mouse tests written, currently there aren't any. Refs #8616, #9953 !strict.

Note: See TracTickets for help on using tickets.