[Laszlo-dev] For Review: Change 20090601-maxcarlson-6 Summary: Fix contextmenu inconsistencies in DHTML
P T Withington
ptw at pobox.com
Tue Jun 2 05:58:43 PDT 2009
I'm also willing to review this (because I am in the same area working
Can we split this as André suggests to simplify the review?
On 2009-06-02, at 08:56EDT, André Bargull wrote:
> I think we should/need to split up these changes to reduce testing
> effort (because it's not only cross-browser, but also cross-OS).
> So, I'd propose to change at first
> "LzKeyboardKernel.__keyboardEvent()" and add
> "__updateControlKeys()". Which leads to my first question: Do
> we need to check for 'metaKey' also "__updateControlKeys()" or just
> in "__keyboardEvent()"?
> On 6/2/2009 3:05 AM, Max Carlson wrote:
>> Change 20090601-maxcarlson-6 by maxcarlson at Bank on 2009-06-01
>> 17:44:36 PDT
>> in /Users/maxcarlson/openlaszlo/trunk-clean
>> for http://svn.openlaszlo.org/openlaszlo/trunk
>> Summary: Fix contextmenu inconsistencies in DHTML
>> Bugs Fixed: LPP-8218 - DHTML: issues with contextmenu onmenuopen,
>> Technical Reviewer: andre.bargull at udo.edu
>> QA Reviewer: hminsky
>> Details: This includes all changes from http://www.openlaszlo.org/pipermail/laszlo-dev/2009-May/021166.html
>> - Andre's changes to improve context menu support. I had to hand-
>> merge LzKeyboardKernel due to changes I'd made related to LPP-8210.
>> LzSprite - [Andre: canceling event-bubbling for all mouse-events
>> => this was already done for all browsers (except Firefox) and all
>> events (except onmouseup). Why wasn't Firefox affected? => All
>> other browsers set "event.keyCode" to '0' for mouse-events, only
>> Firefox sets "keyCode" to 'undefined'. Now take a look at
>> "LzKeyboardKernel.__keyboardEvent()", every event was canceled in
>> that function if "keyCode" was '>= 0'!]
>> Moved detectstuckkeys from capabilities to quirks. Added
>> quirks.noglobaloncontextmenu to deal with Firefox OS X context
>> menu issue - https://bugzilla.mozilla.org/show_bug.cgi?id=443191.
>> __clickDispatcher() looks for quirks.noglobaloncontextmenu to fix
>> context menus in Firefox OS X. Remove unused (e.button == 2 &&
>> eventname != 'oncontextmenu') test from __mouseEvent().
>> LzKeyboardKernel - [Andre move handling for control keys (ctrl,
>> shift, alt) into separate function. It should be obvious why having
>> a single function for both, mouse-events and keyboard-events, is a
>> bad idea (see keyCode issue from above).] Hand-merged tests for
>> meta key/stuck keys checked into r14021.
>> LzMouseKernel - Andre's changes, plus I simplified the contextmenu
>> test to if (eventname == 'oncontextmenu' && targ) - testing for
>> (e.button == 2 && eventname == 'onmouseup') is now handled in
>> Tests: lz.Keys.downKeysArray no longer has extra entries for meta
>> keys, e.g. 'a' after pressing/releasing apple-a on OS X
>> (LPP-8210). test/contextmenu/lpp-6980.lzx?lzr=dhtml shows custom
>> context menus for red and blue boxes and default context menus for
>> purple, yellow and the canvas across Firefox and Safari OS X and
>> Firefox, IE and Safari on Windows. test/lfc/legals/
>> keyboardandmouse.lzx?lzr=dhtml runs as before in Firefox and
>> Safari OS X and Firefox, IE and Safari on Windows.
>> M WEB-INF/lps/lfc/kernel/dhtml/LzKeyboardKernel.js
>> M WEB-INF/lps/lfc/kernel/dhtml/LzSprite.js
>> M WEB-INF/lps/lfc/kernel/dhtml/LzMouseKernel.js
>> Changeset: http://svn.openlaszlo.org/openlaszlo/patches/20090601-maxcarlson-6.tar
More information about the Laszlo-dev