adding popup menu to generate code [message #607127] |
Wed, 13 April 2005 14:03 |
hung 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>
|
|
|
Powered by
FUDForum. Page generated in 0.02755 seconds