Reputation: 1630
At the moment, on my Fancytree a double-click expands a node (which I think is the default) and to edit the node's title Shift-Click works.
In terms of usability in our project, I would prefer to have double-click used to edit a title and a single click to expand/close a node. Is it possible?
Upvotes: 0
Views: 2711
Reputation: 14794
Fancytree exposes click and dblclick event handlers (https://github.com/mar10/fancytree/wiki/TutorialEvents)
However, it might not be a good idea: from jQuery help (http://api.jquery.com/dblclick/):
It is inadvisable to bind handlers to both the click and dblclick events for the same element. The sequence of events triggered varies from browser to browser, with some receiving two click events before the dblclick and others only one. Double-click sensitivity (maximum time between clicks that is detected as a double click) can vary by operating system and browser, and is often user-configurable.
See also here: https://github.com/mar10/fancytree/issues/578
Upvotes: 1