dperez schrieb:
> Hi,
>
> In order to improve the user experience of my app, I'll add context menus.
> I would like them to appear on a right click.
>
> Questions:
> 1) In menu_1.html I have seen this:
>       w1.addEventListener("mousedown", function(e)
>       {
>         e.setPropagationStopped(true);
>       });
>
>     What does the undocumented method setPropagationStopped() do?
>   
This prevents the browser from bubbling the event up in the DOM 
hierarchy. In this case specifically it means that no underlying DOM 
node will receive a click event.
> 2) What's best to use the click or the mousedown event?
>
>   
Use contextmenu. Checking for the right mouse button can be a problem on 
Mac OS.
> 3) How do I force it to appear only on a right click?
>     I have the event.getButton() method to filter, but if I don't test which
> button is pressed, only appears with the left button.
>
>   
Use "contextmenu" ;-)

> Thanks for any answer.
> I'll try to update the doc with helpful answers, in order to avoid re-asking
> the same questions.
>
>   
Great. Bug #270 may be interesting for you: 
<http://bugzilla.qooxdoo.org/show_bug.cgi?id=270>



Best Fabian

-- 
Fabian Jakobs
JavaScript Framework Developer

1&1 Internet AG
Brauerstraße 48
76135 Karlsruhe

Amtsgericht Montabaur HRB 6484

Vorstand: Henning Ahlert, Ralph Dommermuth, Matthias Ehrlich, Andreas Gauger, 
Matthias Greve, Robert Hoffmann, Norbert Lang, Achim Weiss
Aufsichtsratsvorsitzender: Michael Scheeren


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to