| Issue 442: | tree.getNodeByKey() returns node from wrong tree (when there are multiple trees with same keys) | |
| 2 people starred this issue and may be notified of changes. | Back to list |
|
What steps will reproduce the problem?
1. I have two separate trees on a page (e.g. tree1, tree2), each with a visible root node (a node below dynatree's hidden root) whose key is "/" (FYI, my keys are pathnames, although that doesn't matter.)
2. $("#tree2").dynatree("getTree").getNodeByKey("/") returns the root node from tree1.
It seems to me (without looking at your code) that your keys are indexed globally, rather than scoped per tree instance? If so, that's makes the keys unreliable for multiple trees unless we guarantee unique keys across all trees.
Dynatree version 1.2.4, revision 644, 2013-02-12 21:39:36
jQuery 1.9.1
Mac OS X, Safari. (but doesn't matter?)
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
Sep 7, 2013
(No comment was entered for this change.)
Status:
WontFix
Apr 16, 2014
Issue 483 has been merged into this issue. |
||||||||
Labels: -Type-Defect Type-Enhancement Milestone-Release1.2.5