You can simply use the target. e.g.
this.info("What image: " + e.getData());
But I just found that the target is not set upped correctly. Please try
the attached patch and report if it helped.
Modified in SVN with revision #5486.
Greetings,
Sebastian
Alex D. schrieb:
Hi folks,
i have a problem here an would like to know if anybody has any hints for
me: In my app i have a layout with some images in it. Each image has a
context menu like:
=======================*snip*=======================
var com = new qx.client.Command;
com.addEventListener("execute", function(e){
this.info("What image???");
}, this);
var cmenu = new qx.ui.menu.Menu;
var m_1 = new qx.ui.menu.MenuButton("test", null, com);
cmenu .add(m_1);
cmenu .addToDocument();
image.setContextMenu(cmenu);
=======================*snap*=======================
And it works perfectly but i have to know in my command-function what
image have user clicked at. Is there any way to do this? Any help is
really appreciated.
Best Regards,
alex.d
------------------------------------------------------------------------
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
------------------------------------------------------------------------
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
Index: framework/source/class/qx/event/handler/EventHandler.js
===================================================================
--- framework/source/class/qx/event/handler/EventHandler.js (Revision 5482)
+++ framework/source/class/qx/event/handler/EventHandler.js (Arbeitskopie)
@@ -178,7 +178,7 @@
{
// allow the user to stop the event
// through the execute event.
- if (!vCommand.execute()) {
+ if (!vCommand.execute(e.getTarget())) {
e.preventDefault();
}
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel