mirror of
https://github.com/obsproject/obs-studio.git
synced 2024-09-20 04:42:18 +02:00
UI: Set default source toolbar visibility to true
This significantly simplifies the configuration setting's initial load. This also fixes as issue where the source toolbar would initialise as "TextLabel" with enabled buttons if the user had not yet toggled the setting. Fixes #3722
This commit is contained in:
parent
548938c210
commit
a88b262d5f
@ -446,6 +446,8 @@ bool OBSApp::InitGlobalConfigDefaults()
|
||||
true);
|
||||
config_set_default_bool(globalConfig, "BasicWindow", "ShowSourceIcons",
|
||||
true);
|
||||
config_set_default_bool(globalConfig, "BasicWindow",
|
||||
"ShowContextToolbars", true);
|
||||
config_set_default_bool(globalConfig, "BasicWindow", "StudioModeLabels",
|
||||
true);
|
||||
|
||||
|
@ -1770,19 +1770,12 @@ void OBSBasic::OBSInit()
|
||||
GetGlobalConfig(), "BasicWindow", "ShowSourceIcons");
|
||||
ui->toggleSourceIcons->setChecked(sourceIconsVisible);
|
||||
|
||||
if (config_has_user_value(App()->GlobalConfig(), "BasicWindow",
|
||||
"ShowContextToolbars")) {
|
||||
bool visible = config_get_bool(App()->GlobalConfig(),
|
||||
"BasicWindow",
|
||||
"ShowContextToolbars");
|
||||
ui->toggleContextBar->setChecked(visible);
|
||||
ui->contextContainer->setVisible(visible);
|
||||
if (visible)
|
||||
UpdateContextBar(true);
|
||||
} else {
|
||||
ui->toggleContextBar->setChecked(true);
|
||||
ui->contextContainer->setVisible(true);
|
||||
}
|
||||
bool contextVisible = config_get_bool(
|
||||
App()->GlobalConfig(), "BasicWindow", "ShowContextToolbars");
|
||||
ui->toggleContextBar->setChecked(contextVisible);
|
||||
ui->contextContainer->setVisible(contextVisible);
|
||||
if (contextVisible)
|
||||
UpdateContextBar(true);
|
||||
|
||||
{
|
||||
ProfileScope("OBSBasic::Load");
|
||||
|
Loading…
Reference in New Issue
Block a user