From: SourceForge.net <no...@so...> - 2005-09-26 19:28:41
|
Bugs item #1305011, was opened at 2005-09-26 13:05 Message generated for change (Comment added) made by warp9pnt9 You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105757&aid=1305011&group_id=5757 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Fausto (fausto99) Assigned to: Nobody/Anonymous (nobody) Summary: DynElement.captureKeyEvents bug (Part 2) Initial Comment: the dynkeyevent.js file has this method: DynKeyEvent._keyEventListener=function(e) and this lines: if(evt.defaultValue==false) { if(e.cancelBubble) e.cancelBubble=true; if(e.stopPropagation) e.stopPropagation(); } I think it should be: if(evt.defaultValue==false) { if(evt.cancelBubble) e.cancelBubble=true; if(evt.stopPropagation) e.stopPropagation(); } note the evt instead of the e. I changed on my code and worked. The goal? allow one to disable propagation of of key events to the higher hierarchy allowing one to "eat" the keys inside a widget. That's how I found out and fixed it. I have many more fixes too. How should I do it? Fausto. ---------------------------------------------------------------------- >Comment By: L W (warp9pnt9) Date: 2005-09-26 15:28 Message: Logged In: YES user_id=706287 Hi. Have you tested in older browsers to see if it works? I've got IE6 and Firefox 1.0.7 right now. Does there exist an example or can you modify an existing one, or create one from scratch, to demonstrate the problem and the usage you expect? Then attach those files to the bug report. I'd like to see a complex key event example (maybe the game by Raymod / xwisdom is good), with many levels of layers inside a few widgets, and tested in some other browsers. With some things, I just don't know if it was coded wrong initially, or if it was coded that way to specifically work with the browsers at the time it was originally written or last modified. But, looking at 'if (e.cancelBubble) e.cancelBubble=true;' makes little sense. If it's true, set it to true is pointless, so perhaps that was a typo. Which maybe leads to the second 'if (e.stopPropagation) e.stopPropagation()' being a typo. But as that's a function, it may just be a valid check to see if it exists before calling. Hmm, but no, it should exist, so checking would be an error. I'm inclined to accept the patch, but I want to understand it better to be sure. Well, about other bugs or patches, please continue to refer to CVS HEAD. Also, it would be great if you could use diff or diff -u or at the very least include the range of lines that some code is located. It just makes it easier. And as always, attach the patch here or in Patches (no real need to duplicate, I think here would be better). And yes, examples would be good, something that could exist or if newly created, be added to the current examples. Get two things done at once. ;-). ---------------------------------------------------------------------- Comment By: Fausto (fausto99) Date: 2005-09-26 13:08 Message: Logged In: YES user_id=1351973 I am using IE6/7 and Firefox 1.06. DynAPI 3 Beta 2. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105757&aid=1305011&group_id=5757 |