Skip to content

Commit e3d2bac

Browse files
committed
Set the same defaults for custom css field as the old CLR Browser plugin does
1 parent c717c53 commit e3d2bac

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

obs-browser/main-source.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ static void browser_source_get_defaults(obs_data_t *settings)
2828
obs_data_set_default_int(settings, "height", 600);
2929
obs_data_set_default_int(settings, "fps", 30);
3030
obs_data_set_default_bool(settings, "shutdown", true);
31+
obs_data_set_default_string(settings, "css", "body { background-color: rgba(0, 0, 0, 0); margin: 0px auto; overflow: hidden; }");
3132
}
3233

3334
static bool restart_button_clicked(obs_properties_t *props,
@@ -80,6 +81,8 @@ static obs_properties_t *browser_source_get_properties(void *)
8081
obs_module_text("CSS"), OBS_TEXT_MULTILINE);
8182
obs_properties_add_bool(props, "shutdown",
8283
obs_module_text("Shutdown when not active"));
84+
85+
8386
#ifdef __APPLE__
8487
// osx is the only process-isolated cef impl
8588
obs_properties_add_button(props, "restart",

0 commit comments

Comments
 (0)