Is there a way to check if the current maya session is 'new'?
I have a tool created using PyQt, in which it stores the widgets inputs using QSettings (asked this question previously). The settings and all works out great, however I realized that if I launched a new maya session, followed by relaunching my tool, the 'stored' settings is/ are being loaded.
And hence, I would wanted to see if I can implemented in a way such that:
- if user clicks on 'new scene' or open/ load a new file in the current maya session > if my tool is relaunched, it will prompt a popup and ask if User wants to load the 'old' settings or use default settings?
- if user launch a new maya session > open/ load a new file > launch my tool, it should load in the default settings.
Will this be too complicated to do so? I am hoping to implement in the first point if possible.
Many thanks in advance!