|
Re: Diagram layout is still kept when closed editor without saving [message #1710496 is a reply to message #1710473] |
Wed, 07 October 2015 07:47  |
|
Hi Sann,
Le 07/10/2015 05:30, Sann Tran a écrit :
> Hello Obeo guys,
>
> Assume that I have 2 opened diagram editors D1 & D2. Both are in one
> session. I did some steps as following:
>
> 1. I move a node N in D1 (Result: D1 is dirty, and D2 is dirty)
> 2. I close D1. A dialog is showed and ask me to save the D1 diagram or not.
> 3. I don't want to save, so I click "No". The D1 diagram is closed
> 4. I open D1 diagram again.
>
> Result: I still see node N position is changed (because of moving in
> step 1)
> What I expect is that the position of node N is not changed
>
> (Note: If there is only one diagram is opened, every thing is fine.)
You have two opened editor on diagrams (could be table or tree) from the
same aird or modeling project: they share the same editing domain,
resource set and command stack.
When you close the first editor, if you click no: it does not save the
changes you made, ie the files are not saved, but you still have an
editor opened sharing the same modified data so Sirius cannot cancel
your changes.
Note that you can disable this popup when several editors are opened on
the same aird / modeling project: just check the checkbox "Do not prompt
to save on close when still open elsewhere".
When you close the last editor, and select no, Sirius will cancel your
changes (equivalent to a reload of the last saved state) and if changes
are made without opened editor, they will be automatically saved. Note
that both behaviors can be customized using the preferences
SiriusUIPreferencesKeys.PREF_RELOAD_ON_LAST_EDITOR_CLOSE and
SiriusUIPreferencesKeys.PREF_SAVE_WHEN_NO_EDITOR.
>
> It seem to be a strange behavior, and I'm going to fix it. So should you
> please tell me what class I should hook to fix this problem. Or should I
> create a Sirius bug?
>
> Thanks,
>
> Sann
>
>
Regards,
--
Maxime - Obeo
Need training or professional services for Sirius?
http://www.obeodesigner.com/sirius
Maxime Porhel - Obeo
Need training or professional services for Sirius?
http://www.obeodesigner.com/sirius
|
|
|
Powered by
FUDForum. Page generated in 0.01801 seconds