Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Newcomers » Newcomers » Command Core Expressions
Command Core Expressions [message #253934] Tue, 15 April 2008 09:59 Go to next message
Eclipse UserFriend
Originally posted by: anupgokhale.rediffmail.com

Hi all.

I have spent a frustrating day trying to grasp the concepts of the
command core expressions. A few things like using activeEdiorId etc seem
to work fine. But I am simply unable to set handler
enablement/activation using the "instance of" expression and "test"
expressions. Also the entire declarative approach to these expressions
appears to be highly confusing. Can anyone point me to a few
tutorials/articles on the same. I have already checked

http://wiki.eclipse.org/Command_Core_Expressions
http://wiki.eclipse.org/Platform_Command_Framework
http://wiki.eclipse.org/Menu_Contributions

Reading the above I have been able to get some hang about this, but am
still not in a position to fully comprehend and understand the core
expressions.

Can someone help?

Regards,
Anup
Re: Command Core Expressions [message #253972 is a reply to message #253934] Tue, 15 April 2008 18:04 Go to previous message
Felix Dorner is currently offline Felix DornerFriend
Messages: 676
Registered: July 2009
Senior Member
Hey Anup,

I can only give an enablement example. The action is enabled when the
selected element in an the UML2 editor is a "org.eclipse.uml2.uml.Model".
I can understand your desperation, I was very happy when I got this to work.
Maybe the best way to check how things work is to just copy from example
or also bigger plugins.

Felix

<extension
point="org.eclipse.ui.editorActions">
<editorContribution
id="allure.umleditor"
targetID="org.eclipse.uml2.uml.editor.presentation.UMLEditorID ">
<menu
id="allure.umlmenu"
label="Allure"
path="org.eclipse.uml2.umlMenuID/additions-end">
<separator
name="additions">
</separator>
</menu>

<action
class="allure.actions.InsertBehaviorElementsAction"
id="allure.actions.insertBehaviorElements"
label="Insert Behavior Elements"
menubarPath="org.eclipse.uml2.umlMenuID/allure.umlmenu/additions "
style="push">
<enablement>
<objectClass
name="org.eclipse.uml2.uml.Model">
</objectClass>
</enablement>
</action>

</editorContribution>
</extension>
Previous Topic:Plugin executed in separate thread
Next Topic:How to move an icon in the cell of table with JFace/SWT
Goto Forum:
  


Current Time: Thu Aug 08 14:19:34 GMT 2024

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

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

Back to the top