We were looking at http://jira.openlaszlo.org/jira/browse/LPP-8218, which
had an issue with duplicate
events being sent for context menu, and we were looking at this code in
LzMouseKernel.js


        } else if (eventname == 'oncontextmenu' || (e.button == 2 &&
eventname == 'onmouseup') ) {
            Debug.info('mouseEvent', eventname, e);
            if (targ) {
                // update mouse position, required for Safari
                LzMouseKernel.__sendMouseMove(e);
                return LzMouseKernel.__showContextMenu(e);
            }
        } else if (e.button != 2) {

We put that debug print statement in, and in both IE7 and FF/OSX we see that
both a "oncontextmenu" and "onmouseup" event are sent by the browser
(although in different orders in IE7 and FF). So the question is do
we really need to look for the right-button-mouseup event in this clause, or
could it just look for the oncontextmenu
event to decide to show a menu? This might help fix this issue with
duplicate events, and get rid of the "this.__sentshowevent" check in
LzCOntextMenuKernel ? And maybe that in turn might help to fix the bug where
you
don't get a new 'oncontextmenu' event when you right click on a menu that's
already open..?

-- 
Henry Minsky
Software Architect
[email protected]

Reply via email to