mirror of
https://github.com/obsproject/obs-studio.git
synced 2026-03-03 14:16:36 -05:00
UI: Add option to save projectors
This adds an option to the general settings to save the opened projectors on exit. (Note: Fixed conflicts -Jim) Closes jp9000/obs-studio#743
This commit is contained in:
@@ -282,6 +282,7 @@ OBSBasicSettings::OBSBasicSettings(QWidget *parent)
|
||||
HookWidget(ui->systemTrayEnabled, CHECK_CHANGED, GENERAL_CHANGED);
|
||||
HookWidget(ui->systemTrayWhenStarted,CHECK_CHANGED, GENERAL_CHANGED);
|
||||
HookWidget(ui->systemTrayAlways, CHECK_CHANGED, GENERAL_CHANGED);
|
||||
HookWidget(ui->saveProjectors, CHECK_CHANGED, GENERAL_CHANGED);
|
||||
HookWidget(ui->snappingEnabled, CHECK_CHANGED, GENERAL_CHANGED);
|
||||
HookWidget(ui->screenSnapping, CHECK_CHANGED, GENERAL_CHANGED);
|
||||
HookWidget(ui->centerSnapping, CHECK_CHANGED, GENERAL_CHANGED);
|
||||
@@ -896,6 +897,10 @@ void OBSBasicSettings::LoadGeneralSettings()
|
||||
"BasicWindow", "SysTrayMinimizeToTray");
|
||||
ui->systemTrayAlways->setChecked(systemTrayAlways);
|
||||
|
||||
bool saveProjectors = config_get_bool(GetGlobalConfig(),
|
||||
"BasicWindow", "SaveProjectors");
|
||||
ui->saveProjectors->setChecked(saveProjectors);
|
||||
|
||||
bool snappingEnabled = config_get_bool(GetGlobalConfig(),
|
||||
"BasicWindow", "SnappingEnabled");
|
||||
ui->snappingEnabled->setChecked(snappingEnabled);
|
||||
@@ -2351,6 +2356,11 @@ void OBSBasicSettings::SaveGeneralSettings()
|
||||
config_set_bool(GetGlobalConfig(),
|
||||
"BasicWindow", "SysTrayMinimizeToTray",
|
||||
ui->systemTrayAlways->isChecked());
|
||||
|
||||
if (WidgetChanged(ui->saveProjectors))
|
||||
config_set_bool(GetGlobalConfig(), "BasicWindow",
|
||||
"SaveProjectors",
|
||||
ui->saveProjectors->isChecked());
|
||||
}
|
||||
|
||||
void OBSBasicSettings::SaveStream1Settings()
|
||||
|
||||
Reference in New Issue
Block a user