Skip to content

Commit

Permalink
UI: Fix always on top not being saved on exit
Browse files Browse the repository at this point in the history
By the time we reach this part of the code it's too late to be checking
the window flags as the window has already been closed.
  • Loading branch information
notr1ch authored and jp9000 committed Nov 5, 2022
1 parent aca4815 commit c1841e4
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions UI/window-basic-main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2701,12 +2701,10 @@ OBSBasic::~OBSBasic()
OBS_BETA_VER);
#endif

bool alwaysOnTop = IsAlwaysOnTop(this);

config_set_bool(App()->GlobalConfig(), "BasicWindow", "PreviewEnabled",
previewEnabled);
config_set_bool(App()->GlobalConfig(), "BasicWindow", "AlwaysOnTop",
alwaysOnTop);
ui->actionAlwaysOnTop->isChecked());
config_set_bool(App()->GlobalConfig(), "BasicWindow",
"SceneDuplicationMode", sceneDuplicationMode);
config_set_bool(App()->GlobalConfig(), "BasicWindow", "SwapScenesMode",
Expand Down

0 comments on commit c1841e4

Please sign in to comment.