Shared editing domain problem [message #533734] |
Sun, 16 May 2010 11:58 |
Eclipse User |
|
|
|
Originally posted by: ML1984.gmx.de
Hello,
I am experiencing difficulties adapting an emf generated editor to use a
shared editing domain. (I do not want to integrate emf and gmf generated
editors, I just want to have them a shared editing domain.)
The following article shows where to start:
http://www.eclipse.org/articles/Article-Integrating-EMF-GMF- Editors/index.html#upgrading_the_editing_domain
My code looks similar to the one presented in the article except:
TransactionalEditingDomain editingDomain =
TransactionalEditingDomain.Registry.INSTANCE
..getEditingDomain("id_xyz");
However, the emf generated editor shows not the expected behavior. When
saving a diagram in the gmf generated editor, the emf generated one does
not remove its dirty flag. Sometimes the emf generated one does not even
show a dirty flag when a change is made in the gmf generated one.
What are the reasons for this? How can I achieve the expected behavior?
Cheers,
Mark
|
|
|
Re: Shared editing domain problem [message #533740 is a reply to message #533734] |
Sun, 16 May 2010 13:15 |
Ed Merks Messages: 33142 Registered: July 2009 |
Senior Member |
|
|
Mark,
The command stack listener should update the dirty state whenever a
command is invoked, so I'd have a look at what's going on there. I'm
not sure how saving in one editor informs the other editor; it needs to
ensure that firePropertyChange(IEditorPart.PROP_DIRTY) is called.
Mark L. wrote:
> Hello,
>
> I am experiencing difficulties adapting an emf generated editor to use a
> shared editing domain. (I do not want to integrate emf and gmf generated
> editors, I just want to have them a shared editing domain.)
> The following article shows where to start:
>
> http://www.eclipse.org/articles/Article-Integrating-EMF-GMF- Editors/index.html#upgrading_the_editing_domain
>
> My code looks similar to the one presented in the article except:
>
> TransactionalEditingDomain editingDomain =
> TransactionalEditingDomain.Registry.INSTANCE
> .getEditingDomain("id_xyz");
>
> However, the emf generated editor shows not the expected behavior. When
> saving a diagram in the gmf generated editor, the emf generated one does
> not remove its dirty flag. Sometimes the emf generated one does not even
> show a dirty flag when a change is made in the gmf generated one.
>
> What are the reasons for this? How can I achieve the expected behavior?
>
> Cheers,
> Mark
>
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
Powered by
FUDForum. Page generated in 0.02948 seconds