There is good reason why the markup is flat and not nested. Otherwise
treetable/grid wouldn't be possible.

-Matej

On Wed, Jun 10, 2009 at 5:39 AM, Matt Shannon<mshannon.wic...@gmail.com> wrote:
> Just looking at the firebug profiler, the removeNodes method from tree.js is
> the function that is taking way too long to complete.  Checking the DOM, it
> looks like all nodes in tree regardless of position have their parent node
> set as the wicket panel surrounding the tree.
>
> I would have thought ideally that the various branches of the tree have
> their parents referring to the true tree node parent rather than a single
> common parent. This would allow collapse functions to simply remove all
> nodes of the particular element concerned.
>
> I guess it may be worthwhile experimenting with the following function to
> see if it can be optimized with limited interference.
>
> Wicket.Tree.removeNodes = function(prefix, nodeList) {
>    var problem = false;
>    for (var i = 0; i < nodeList.length; i++) {
>        var e = document.getElementById(prefix + nodeList[i]);
>        if (e != null) {
>            e.parentNode.removeChild(e);
>        } else {
>            // while developing alert a warning
>            problem = true;
>            Wicket.Log.error("Can't find node with id " + prefix +
> nodeList[i] + ". This shouldn't happen - possible bug in tree?");
>        }
>    }
>    if (problem == true) {
>        Wicket.Tree.askForReload();
>    }
> }
>
> thanks
>
> Matt.
>
>
> On Wed, Jun 10, 2009 at 10:39 AM, Igor Vaynberg 
> <igor.vaynb...@gmail.com>wrote:
>
>> On Tue, Jun 9, 2009 at 3:41 PM, Matt Shannon<mshannon.wic...@gmail.com>
>> wrote:
>> > Hi Igor,
>> >
>> > One thing I've learned reading these newsgroups is to not irritate you,
>> or
>> > you don't get a favourable response :)
>>
>> isnt that how most things in life work? :)
>>
>> > I've attached a new quickstart that does have the Start class (which I
>> > appreciate makes debugging from an IDE much simpler).
>>
>> i played around with quickstart. it runs fast in IE8, Safari, and
>> Chrome. Only Firefox, like you mentioned, is afflicted. I am not sure
>> why the dom node removal is so slow in firefox, we may have to roll
>> special javascript just for firefox to handle this...i am not,
>> however, sure what will work fast because already we are not doing
>> anything special to remove the dom node.
>>
>> -igor
>>
>> >
>> > The maven jetty plugin is also configured with contextpath "/"
>> > e.g.
>> >
>> > mvn jetty:run
>> > http://localhost:8080
>> >
>> > thanks,
>> >
>> > Matt.
>> >
>> >
>> >
>> > On Wed, Jun 10, 2009 at 12:45 AM, Igor Vaynberg <igor.vaynb...@gmail.com
>> >
>> > wrote:
>> >>
>> >> seems your quickstart is not a quickstart - eg its missing the Start
>> >> launcher usually found in src/test/java of the quickstart
>> >> archetype/project.
>> >>
>> >> -igor
>> >>
>> >> On Tue, Jun 9, 2009 at 2:09 AM, Matt Shannon<mshannon.wic...@gmail.com>
>> >> wrote:
>> >> > Hi,
>> >> >
>> >> > First time poster, but have been lurking for a few crazy months trying
>> >> > to
>> >> > learn and develop with this technology.  I'm prototyping a wicket app
>> >> > for
>> >> > work, and have been extremely impressed with this framework and also
>> the
>> >> > support and information that can be found on these mailing lists.
>> >> >
>> >> > The one component in wicket I have found that seems most difficult to
>> >> > leverage in an AJAX / dynamic on demand nature seems to be the tree
>> >> > component. I've hobbled together a dynamic tree leveraging bits and
>> >> > pieces
>> >> > of other peoples work (mostly from this mailing list).  The tree seems
>> >> > to
>> >> > work ok, but I have run in to a strange performance issue on firefox
>> >> > when
>> >> > attempting to collapse a node.
>> >> >
>> >> > Firefox has serious performance issues when collapsing nodes with a
>> >> > semi-large number of children (e.g. 100+ children).
>> >> >
>> >> > I've attached a quickstart that demonstrates the issue (Firefox
>> 3.0.10).
>> >> >
>> >> > The collapse performance issue does not appear to affect IE6.
>> >> >
>> >> > I would be interested to see if anyone can conform this issue (based
>> on
>> >> > the
>> >> > attached quickstart), and suggest a mechanism that may combat this.
>> >> >
>> >> > In my 'real' application, my nodes have real detachable models
>> >> > associated
>> >> > with each tree node.
>> >> >
>> >> > cheers
>> >> >
>> >> > Matt.
>> >> >
>> >> >
>> >> >
>> >> >
>> >> > ---------------------------------------------------------------------
>> >> > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> >> > For additional commands, e-mail: users-h...@wicket.apache.org
>> >> >
>> >>
>> >> ---------------------------------------------------------------------
>> >> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> >> For additional commands, e-mail: users-h...@wicket.apache.org
>> >>
>> >
>> >
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> > For additional commands, e-mail: users-h...@wicket.apache.org
>> >
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> For additional commands, e-mail: users-h...@wicket.apache.org
>>
>>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to