Hey,
I would suggest to use the tree controllers selection instead. It contains the
model data which you need. Just use the change event of the selection array.
treecontroller.getSelection().addListener("change", function() {
var selectedItem = treecontroller.getSelection().getItem(0);
}, this);
Btw. if you use the from controller, you can directly use the SelectedItem as
model. :)
Regards,
Martin
Am 01.10.2012 um 14:59 schrieb Michael <[email protected]>:
> Hi,
>
> I'm quite new to qooxdoo *and* Javascript and it seems I'm not getting
> around the method to bind the selected data of the tree to some other
> view (a form).
>
> I'm able to create a model out of a json data structure and bind it to
> the tree (and it shows up).
> What I want to do now is:
>
> If an item of the tree is selected I want to generate a form out of
> another property of the treedata. So I have the properties "name","kids"
> and "details". The detail preoperty is only for showing up in a own
> generated form (to change it).
>
> My idea of doing this is binding to the changeSelection event of the
> tree and with that info generate the required form.
> But how do I get the data from the event (after ev.getData() )?
>
> I'm missing something to make it click :-)
>
> Thanks for answering,
> Michael
>
>
>
> ------------------------------------------------------------------------------
> Got visibility?
> Most devs has no idea what their production app looks like.
> Find out how fast your code is with AppDynamics Lite.
> http://ad.doubleclick.net/clk;262219671;13503038;y?
> http://info.appdynamics.com/FreeJavaPerformanceDownload.html
> _______________________________________________
> qooxdoo-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
------------------------------------------------------------------------------
Don't let slow site performance ruin your business. Deploy New Relic APM
Deploy New Relic app performance management and know exactly
what is happening inside your Ruby, Python, PHP, Java, and .NET app
Try New Relic at no cost today and get our sweet Data Nerd shirt too!
http://p.sf.net/sfu/newrelic-dev2dev
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel