Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » Visual Editor (VE) » adding popup menu to generate code
adding popup menu to generate code [message #607127] Wed, 13 April 2005 14:03
hung is currently offline hungFriend
Messages: 117
Registered: July 2009
Senior Member
Hello,
Can someone advise on how to do this :

I need to add a menu/action, this will add something like
"button.setData("myKey",myObject);" to the initialize() method.

I was able to add the menu (see below). However, I am not sure which
command, or policy to use to insert the code to the VisualEditor. I 've
been looking at RenameJavaBeanObjectActionDelegate.java,
ControlDirectEditPolicy.java, etc... Can someone tell me where I should
start? Thanks.

<extension point="org.eclipse.ui.popupMenus">
<objectContribution
objectClass=" org.eclipse.ve.internal.java.core.IJavaBeanContextMenuContri butor "
id=" org.eclipse.ve.internal.swt.editorpart.settextaction.popup.o bject ">
<filter name="BEANTYPE" value="org.eclipse.swt.widgets.Control"> </filter>
<filter name="PROPERTY" value="data"></filter>
<action
label="Bind (Testing)"
class="com.ibm.vetest.actions.TestVEAction"
id="VEExtTest.newAction1">
</action>
</objectContribution>
Previous Topic:Moving from JBuilder to Eclipse
Next Topic:how stable is ve 1.1.x with M6 ?
Goto Forum:
  


Current Time: Sat Apr 27 01:44:13 GMT 2024

Powered by FUDForum. Page generated in 0.02755 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top