Hi Norbert,

> I'm currently struggling with context menus in the HtmlArea widget.
> When performing a right click within the text area of the widget I would
> like it to display a popup menu at the mouse cursor position, however, it
> refuses to do so. With the default settings the menu gets placed at the 
> bottom-
> left  corner of the widget (cf.  http://tinyurl.com/394ytbx
> http://tinyurl.com/394ytbx ). I have tried different placement
> settings, including the menu's openToMouse method, but - nada.
> 
> Any hints or instructions are appreciated.
The contextmenu can easily be positioned using the data of the "contextmenu" 
event which is fired by the HtmlArea. This event is delivering the relative (= 
to the HtmlArea) and the absolute X and Y coords. Just check the given data of 
the event.

--snip--
htmlArea.addListener("contextmenu", function(e)
{
  this.debug(this.popupMenu.getPlaceMethod());
  this.popupMenu.open();
  var positions = e.getData();
}, this);
--snip-- 

I have to admit that the documentation (for the UI-level component) for this 
event and the data has to be completed (I already added it to the current 
branch and the trunk).

The low-level component is already documented correctly.
-> http://demo.qooxdoo.org/current/apiviewer/#qx.bom.htmlarea.HtmlArea

Regards,
  Alex

------------------------------------------------------------------------------
Download new Adobe(R) Flash(R) Builder(TM) 4
The new Adobe(R) Flex(R) 4 and Flash(R) Builder(TM) 4 (formerly 
Flex(R) Builder(TM)) enable the development of rich applications that run
across multiple browsers and platforms. Download your free trials today!
http://p.sf.net/sfu/adobe-dev2dev
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to