UI: Better Hide OBS Window description, add first time dialog & tooltip

This commit is contained in:
Matt Gajownik
2022-01-23 12:27:18 +11:00
committed by Jim
parent 59ab9c98fb
commit e2e751aa55
4 changed files with 28 additions and 1 deletions

View File

@@ -1241,6 +1241,9 @@ void OBSBasicSettings::LoadGeneralSettings()
config_get_bool(GetGlobalConfig(), "BasicWindow",
"HideOBSWindowsFromCapture");
ui->hideOBSFromCapture->setChecked(hideWindowFromCapture);
connect(ui->hideOBSFromCapture, SIGNAL(stateChanged(int)), this,
SLOT(HideOBSWindowWarning(int)));
}
#endif
@@ -4209,6 +4212,24 @@ void OBSBasicSettings::SpeakerLayoutChanged(int idx)
}
}
void OBSBasicSettings::HideOBSWindowWarning(int state)
{
if (loading || state == Qt::Unchecked)
return;
if (config_get_bool(GetGlobalConfig(), "General",
"WarnedAboutHideOBSFromCapture"))
return;
OBSMessageBox::information(
this, QTStr("Basic.Settings.General.HideOBSWindowsFromCapture"),
QTStr("Basic.Settings.General.HideOBSWindowsFromCapture.Message"));
config_set_bool(GetGlobalConfig(), "General",
"WarnedAboutHideOBSFromCapture", true);
config_save_safe(GetGlobalConfig(), "tmp", nullptr);
}
/*
* resets current bitrate if too large and restricts the number of bitrates
* displayed when multichannel OFF