Search the web
Sign In
New User? Sign Up
ydn-javascript · Yahoo! User Interface Library Group
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Hear how Yahoo! Groups has changed the lives of others. Take me there.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
eventing problems on TreeView with complex HTMLNode   Message List  
Reply | Forward Message #50239 of 52114 |
Re: [ydn-javascript] eventing problems on TreeView with complex HTMLNode

The problem is that you are not capturing the events yourself in the
controls you have added and preventing their propagation up to their
containers. Events at any level bubble up through the DOM element
hierarchy unless it is explicitly prevented. You are not preventing
this effect and it will simply bubble up naturally and will be picked up
by whatever listener is out there, in this case the key and click events
of the container. So, one way is for you to put listeners for the
events you want to allow in this events and use
YAHOO.util.Event.stopPropagation to prevent the bubbling from reaching
the TreeView or you could place your controls in floating panels outside
of the TreeView hierarchy and have them position and show at the
appropriate places when needed. Being outside of the same DOM branch,
their events cannot bubble into a lateral branch.

Satyam


blakesys escribió:
> I have this really pesky problem with YUI. It has been bothering me for a
long time, and I cannot figure it out.
>
> I am using a YAHOO.widget.TreeView with many YAHOO.widget.HTMLNode objects as
the leaf nodes of the tree.
>
> My HTMLNode has complex html that has a gui in of itself that can receive
keyboard input, has drop down menus etc.
>
> The problem is that the tree is somehow interfering with routine events in my
HTMLNode such that I cannot even type in a text box without holding the mouse
down.
>
> I cannot figure out how to configure the tree to leave the events alone.
>
> Here is a small self-contained example that demonstrates the problem:
>
> http://arthurblake.thruhere.net/treeviewproblem.html
>
> Thanks in advance for any help or insight you might have...
>
>
>
> ------------------------------------
>
> Yahoo! Groups Links
>
>
>
> ------------------------------------------------------------------------
>
>
> No virus found in this incoming message.
> Checked by AVG - www.avg.com
> Version: 8.5.375 / Virus Database: 270.13.3/2217 - Release Date: 07/03/09
18:11:00
>
>



Sat Jul 4, 2009 4:53 pm

satyamutsa
Offline Offline
Send Email Send Email

Forward
Message #50239 of 52114 |
Expand Messages Author Sort by Date

I have this really pesky problem with YUI. It has been bothering me for a long time, and I cannot figure it out. I am using a YAHOO.widget.TreeView with many...
blakesys
Offline Send Email
Jul 4, 2009
3:33 pm

The problem is that you are not capturing the events yourself in the controls you have added and preventing their propagation up to their containers. Events...
Satyam
satyamutsa
Offline Send Email
Jul 4, 2009
4:56 pm

Thanks for your reply. That is one of the first things I tried. But it doesn't work. Here is my example that tries to stop the events: ...
blakesys
Offline Send Email
Jul 4, 2009
7:04 pm

If you check the values of variables search and fruits at the time of setting the listeners for the events, both are null because the calls to getElementById...
Satyam
satyamutsa
Offline Send Email
Jul 5, 2009
11:20 am

Thank you very much! I finally got it working....
blakesys
Offline Send Email
Jul 6, 2009
1:58 am
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help