Auto update not fully working ? [message #1384226] |
Wed, 28 May 2014 09:08  |
Eclipse User |
|
|
|
Hi all,
Following Graphiti tutorial, I did override the following methods in my diagram type provider :
@Override
public boolean isAutoUpdateAtStartup() {
return true;
}
@Override
public boolean isAutoUpdateAtRuntimeWhenEditorIsSaved() {
return true;
}
Considering the default behavior is 'true' for 'isAutoUpdateAtRuntime' and 'isAutoUpdateAtReset', my diagram should be updated automatically in all situations.
But it only successfully happens at startup...
Any idea why ?
Regards,
Laurent
|
|
|
|
|
|
|
|
|
Re: Auto update not fully working ? [message #1385336 is a reply to message #1385101] |
Thu, 05 June 2014 13:17  |
Eclipse User |
|
|
|
Hi Michael,
The problem with sharing the transactionnal editing domain (TED) and its associated command stack is indeed that the user will be able to perform undos/redos in an editor concerning modifications that took place in another editor...
Moreover, I'm not a specialist either but I don't think the behavior you described applies to CDO. That is : each editor having its own copy of the EMF model in
memory.
In my case, I have a dedicated TED per editor but they all share a single underlying CDO transaction.
Now, considering that it's possible to commit only a part of the transaction and that each editor works on a distinct EMF/CDO resource, when an editor is saved, only the modified elements in its resource are commited.
The other opened editor listen to commit events triggered by CDO and I ask for an update in case their resource has a "external" reference to an element that has been commited by a direct editing and whose display must be refreshed.
Regards,
Laurent
|
|
|
Powered by
FUDForum. Page generated in 0.30983 seconds