pcirella / dynatree

Automatically exported from code.google.com/p/dynatree
0 stars 0 forks source link

When using Lazy Loading, "expand" is ignored #228

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I lazy load all my data. No matter what I set (i.e. "expand: false"), the nodes 
always show as expanded. This would be OK if it then recursively lazy loaded 
those nodes, but it doesn't.

Original issue reported on code.google.com by Randg...@gmail.com on 30 Sep 2011 at 4:58

GoogleCodeExporter commented 9 years ago
OK - it seems to be because I have "persist" set to true. If I turn off persist 
it works correctly.

Original comment by Randg...@gmail.com on 30 Sep 2011 at 5:17

GoogleCodeExporter commented 9 years ago

Original comment by moo...@wwwendt.de on 3 Oct 2011 at 8:49

GoogleCodeExporter commented 9 years ago
considered verified

Original comment by moo...@wwwendt.de on 17 Jul 2012 at 4:16

GoogleCodeExporter commented 9 years ago

Original comment by moo...@wwwendt.de on 17 Jul 2012 at 4:19

GoogleCodeExporter commented 9 years ago

Original comment by moo...@wwwendt.de on 26 Jan 2013 at 4:08

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Hello,
I seem to be having a similar problem. I am expanding the node onRender to 
recursively open the children of a lazy tree. The tree opens up perfectly. 
However, I am unable to close a sub-branch when I click on the '-' sign. 
I am using dynaTree 1.2.4 and the console says " dtnode._expand(true) IGNORED 
". Could you help me out with this bit? I am sure I am missing something here 
and this thread is the closest thread that I found on the internet. 

Original comment by anirudh....@gmail.com on 12 Nov 2013 at 3:12

GoogleCodeExporter commented 9 years ago
I think doing this inside onRender might cause the problem. Try to expand the 
nodes after loading (postInit)

Original comment by moo...@wwwendt.de on 12 Nov 2013 at 6:33

GoogleCodeExporter commented 9 years ago
Yes, you are right. I realized that soon afterx
Actually, I am doing something like this. I have a link call expand all. When I 
click on expand all , I need to expand all the lazy nodes. The data comes from 
the server, which is queried using a toolkit and brought into dynaTree format. 
This function is inside onLazyRead. So, I thought doing a node.expand(true) 
inside onRender would work. It looks like the event fires even when you close a 
node. Hence the deadlock.
Any clue as to how I can deal with expand all? 

Original comment by anirudh....@gmail.com on 12 Nov 2013 at 6:58