OmSessionStore and SnapshotDone event (was: saving an image on windows and opening it on mac problems)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

OmSessionStore and SnapshotDone event (was: saving an image on windows and opening it on mac problems)

Andrei Chis
Hi,

OmSessionStore registers an action (OmSessionStore>>#store) when the event SnapshotDone is triggered.
However this event is triggered immediately when an image is opened after being saved, before the file system was reset.
This means that OmSessionStore>>#store is called before the file system is reset.
Hence, if you save an image on windows and open it on mac you run into issues as OmSessionStore>>#store performs file operations that will work with a WindowsStore instead of a MacStore.

Does OmSessionStore need to register to SnapshotDone events?
When the image is opened OmSessionStore>>#store will be called anyway as OmSessionStore registers a start-up action.

Cheers,
Andrei
Reply | Threaded
Open this post in threaded view
|

Re: OmSessionStore and SnapshotDone event (was: saving an image on windows and opening it on mac problems)

tinchodias


El 26/4/2017 12:22, "Andrei Chis" <[hidden email]> escribió:
Hi,

OmSessionStore registers an action (OmSessionStore>>#store) when the event SnapshotDone is triggered.
However this event is triggered immediately when an image is opened after being saved, before the file system was reset.
This means that OmSessionStore>>#store is called before the file system is reset.
Hence, if you save an image on windows and open it on mac you run into issues as OmSessionStore>>#store performs file operations that will work with a WindowsStore instead of a MacStore.

Does OmSessionStore need to register to SnapshotDone events?
When the image is opened OmSessionStore>>#store will be called anyway as OmSessionStore registers a start-up action.

#store doesn' t need to be done twice. I can see it tonight.

Martín



Cheers,
Andrei

Reply | Threaded
Open this post in threaded view
|

Re: OmSessionStore and SnapshotDone event (was: saving an image on windows and opening it on mac problems)

Denis Kudriashov
In reply to this post by Andrei Chis

2017-04-26 17:21 GMT+02:00 Andrei Chis <[hidden email]>:
Hi,

OmSessionStore registers an action (OmSessionStore>>#store) when the event SnapshotDone is triggered.
However this event is triggered immediately when an image is opened after being saved, before the file system was reset.
This means that OmSessionStore>>#store is called before the file system is reset.
Hence, if you save an image on windows and open it on mac you run into issues as OmSessionStore>>#store performs file operations that will work with a WindowsStore instead of a MacStore.

Maybe we should remove this event at all because subscribing on it is not safe. Users should use SessionManager registration mechanizm driven by categories and priorities 
Reply | Threaded
Open this post in threaded view
|

Re: OmSessionStore and SnapshotDone event (was: saving an image on windows and opening it on mac problems)

Denis Kudriashov

2017-04-27 21:11 GMT+02:00 Denis Kudriashov <[hidden email]>:
2017-04-26 17:21 GMT+02:00 Andrei Chis <[hidden email]>:
Hi,

OmSessionStore registers an action (OmSessionStore>>#store) when the event SnapshotDone is triggered.
However this event is triggered immediately when an image is opened after being saved, before the file system was reset.
This means that OmSessionStore>>#store is called before the file system is reset.
Hence, if you save an image on windows and open it on mac you run into issues as OmSessionStore>>#store performs file operations that will work with a WindowsStore instead of a MacStore.

Maybe we should remove this event at all because subscribing on it is not safe. Users should use SessionManager registration mechanizm driven by categories and priorities 

I think SnapshotDone is supposed to be announced after all startup actions. And here is a bug where it is wrong
Reply | Threaded
Open this post in threaded view
|

Re: OmSessionStore and SnapshotDone event (was: saving an image on windows and opening it on mac problems)

Denis Kudriashov
I open issue 20004. We need decide what the proper logic

2017-04-27 21:15 GMT+02:00 Denis Kudriashov <[hidden email]>:

2017-04-27 21:11 GMT+02:00 Denis Kudriashov <[hidden email]>:
2017-04-26 17:21 GMT+02:00 Andrei Chis <[hidden email]>:
Hi,

OmSessionStore registers an action (OmSessionStore>>#store) when the event SnapshotDone is triggered.
However this event is triggered immediately when an image is opened after being saved, before the file system was reset.
This means that OmSessionStore>>#store is called before the file system is reset.
Hence, if you save an image on windows and open it on mac you run into issues as OmSessionStore>>#store performs file operations that will work with a WindowsStore instead of a MacStore.

Maybe we should remove this event at all because subscribing on it is not safe. Users should use SessionManager registration mechanizm driven by categories and priorities 

I think SnapshotDone is supposed to be announced after all startup actions. And here is a bug where it is wrong