mirror of
https://github.com/obsproject/obs-studio.git
synced 2024-07-19 09:39:15 +00:00
UI: Add scene collection cleanup event to frontend API
This event is called when all scene data has been unloaded.
This commit is contained in:
parent
bf31e1c233
commit
6cd79f8105
|
@ -40,7 +40,9 @@ enum obs_frontend_event {
|
|||
|
||||
OBS_FRONTEND_EVENT_STUDIO_MODE_ENABLED,
|
||||
OBS_FRONTEND_EVENT_STUDIO_MODE_DISABLED,
|
||||
OBS_FRONTEND_EVENT_PREVIEW_SCENE_CHANGED
|
||||
OBS_FRONTEND_EVENT_PREVIEW_SCENE_CHANGED,
|
||||
|
||||
OBS_FRONTEND_EVENT_SCENE_COLLECTION_CLEANUP
|
||||
};
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
|
|
|
@ -3343,6 +3343,9 @@ void OBSBasic::ClearSceneData()
|
|||
|
||||
obs_enum_sources(cb, nullptr);
|
||||
|
||||
if (api)
|
||||
api->on_event(OBS_FRONTEND_EVENT_SCENE_COLLECTION_CLEANUP);
|
||||
|
||||
disableSaving--;
|
||||
|
||||
blog(LOG_INFO, "All scene data cleared");
|
||||
|
|
Loading…
Reference in a new issue