X-Git-Url: https://git.stderr.nl/gitweb?a=blobdiff_plain;f=player%2Fmain.c;h=5ed1d0e9df2049d19e4031549a9aedfaa88f7a66;hb=e70e5d07e5071b71c6a064a3d1be1a468b494c1a;hp=8d797c37ff245879f7ec3e73e5cb64bab28e1b75;hpb=4ef3858a07012fedc96a1a3a8545545149406cd6;p=projects%2Fchimara%2Fchimara.git diff --git a/player/main.c b/player/main.c index 8d797c3..5ed1d0e 100644 --- a/player/main.c +++ b/player/main.c @@ -118,7 +118,13 @@ create_window(void) aboutwindow = GTK_WIDGET(load_object("aboutwindow")); prefswindow = GTK_WIDGET(load_object("prefswindow")); GtkActionGroup *actiongroup = GTK_ACTION_GROUP(load_object("actiongroup")); + + /* Set the default value of the "View/Toolbar" menu item upon creation of a + new window to the "show-toolbar-default" setting, but bind the setting + one-way only - we don't want toolbars to disappear suddenly */ GtkToggleAction *toolbar_action = GTK_TOGGLE_ACTION(load_object("toolbar")); + gtk_toggle_action_set_active(toolbar_action, g_settings_get_boolean(state_settings, "show-toolbar-default")); + g_settings_bind(state_settings, "show-toolbar-default", toolbar_action, "active", G_SETTINGS_BIND_SET); const gchar **ptr; GtkRecentFilter *filter = gtk_recent_filter_new(); @@ -164,24 +170,6 @@ create_window(void) } #endif /* DEBUG */ } - chimara_if_set_preferred_interpreter(CHIMARA_IF(glk), - CHIMARA_IF_FORMAT_Z5, - CHIMARA_IF_INTERPRETER_FROTZ); - chimara_if_set_preferred_interpreter(CHIMARA_IF(glk), - CHIMARA_IF_FORMAT_Z6, - CHIMARA_IF_INTERPRETER_NITFOL); - chimara_if_set_preferred_interpreter(CHIMARA_IF(glk), - CHIMARA_IF_FORMAT_Z8, - CHIMARA_IF_INTERPRETER_FROTZ); - chimara_if_set_preferred_interpreter(CHIMARA_IF(glk), - CHIMARA_IF_FORMAT_Z_BLORB, - CHIMARA_IF_INTERPRETER_FROTZ); - chimara_if_set_preferred_interpreter(CHIMARA_IF(glk), - CHIMARA_IF_FORMAT_GLULX, - CHIMARA_IF_INTERPRETER_GLULXE); - chimara_if_set_preferred_interpreter(CHIMARA_IF(glk), - CHIMARA_IF_FORMAT_GLULX_BLORB, - CHIMARA_IF_INTERPRETER_GLULXE); /* DON'T UNCOMMENT THIS your eyes will burn but it is a good test of programmatically altering just one style