mirror of
https://github.com/obsproject/obs-studio.git
synced 2026-04-26 01:21:58 -04:00
UI: Move obs startup/shutdown to obs-app.cpp
Now that we aren't dependent upon a window for our context, we can safely move the obs context creation/destruction to obs-app.cpp, and use the OBSContext helper class to automatically shut down obs.
This commit is contained in:
@@ -841,8 +841,6 @@ void OBSBasic::OBSInit()
|
||||
if (ret <= 0)
|
||||
throw "Failed to get scene collection json file path";
|
||||
|
||||
if (!obs_startup(App()->GetLocale()))
|
||||
throw "Failed to initialize libobs";
|
||||
if (!InitBasicConfig())
|
||||
throw "Failed to load basic.ini";
|
||||
if (!ResetAudio())
|
||||
@@ -1114,8 +1112,6 @@ OBSBasic::~OBSBasic()
|
||||
* expect or want it to. */
|
||||
QApplication::sendPostedEvents(this);
|
||||
|
||||
obs_shutdown();
|
||||
|
||||
config_set_int(App()->GlobalConfig(), "General", "LastVersion",
|
||||
LIBOBS_API_VER);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user