Skip to main content

Extend yahoo tree widget

2 replies [Last post]
viggonavarsete
Offline
Joined: 2007-06-17
Points: 0

Is it possible to extend the yahoo tree widget so that you get a checkbox next to each item in the tree? I want to be able to select/deselect items from the tree, and change the datamodel based on the selection.

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
gmurray71
Offline
Joined: 2003-07-31
Points: 0

This level of customization would require you modify the yahoo/tree/component.js file. While not too hard to do you would then be limited to what the yahoo tree API allows.

Yahoo has detailed documentaiton about this here:

http://developer.yahoo.com/yui/treeview/#customtypes

If you provide a re-usable solution that might be able to use we'd love to have you contribute them back to the project.

-Greg

viggonavarsete
Offline
Joined: 2007-06-17
Points: 0

Thanks for your reply Greg!

I will look into the customtypes at the yahoo site. This example is what I need implemented as a jMaki widget: http://developer.yahoo.com/yui/examples/treeview/check.html

I will first play with the yahoo version, and when I understand how it's working, I will (hopefully) be able to create a reusable solution that can be contributed to the jMaki project :)