Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » can "tpyeMapper" return a EObject?
can "tpyeMapper" return a EObject? [message #187057] Wed, 14 May 2008 23:31 Go to next message
Eclipse UserFriend
Originally posted by: hufangjian31.hotmail.com

Hi, all
I am not good at programming and new to GMF tab View and I have tried to
solve this problem for several days.
I want to crete a new tab in the GMF property view(which is realy
importment to my project), but when you select a figure node in GMF, you
select the EditPart of it. If I want to change the EditPart to Semantic
Model(like when you select a node in EMF editor), I try to use the
typeMapper of the contributor. but if I let the class implement
ITypeMapper, is it must return a class? I think I can get the EObject
using:
EditPart actor_editpart = (EditPart)((IStructuredSelection)
object).getFirstElement();
eObject = (EObject)
((org.eclipse.gmf.runtime.notation.View)
actor_editpart.getModel()).getElement();

So how can I let the typeMapper return a EObject?

Thanks in advance!
Re: can "tpyeMapper" return a EObject? [message #187172 is a reply to message #187057] Thu, 15 May 2008 09:48 Go to previous message
Alexander Shatalin is currently offline Alexander ShatalinFriend
Messages: 2928
Registered: July 2009
Senior Member
Hello Fangjian,

Try adding new CustomPropertyTab below PropertySheet node in your genmodel
and generate the code. Then you can modify generated code to let it display
proper properties tab..

-----------------
Alex Shatalin
Previous Topic:Howto Revert Mistakes
Next Topic:RCP unexpected type
Goto Forum:
  


Current Time: Thu Apr 18 02:48:53 GMT 2024

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

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

Back to the top