mirror of
https://github.com/kanjitalk755/macemu.git
synced 2024-12-22 13:30:07 +00:00
Added "Save Preferences" menu item
This commit is contained in:
parent
aaf67fd59a
commit
c727bc0df7
@ -396,6 +396,13 @@ static void window_destroyed(void)
|
||||
gtk_main_quit();
|
||||
}
|
||||
|
||||
// "Save" button clicked
|
||||
static void cb_save(...)
|
||||
{
|
||||
read_settings();
|
||||
SavePrefs();
|
||||
}
|
||||
|
||||
// "Start" button clicked
|
||||
static void cb_start(...)
|
||||
{
|
||||
@ -462,6 +469,7 @@ static void mn_zap_pram(...)
|
||||
static GtkItemFactoryEntry menu_items[] = {
|
||||
{(gchar *)GetString(STR_PREFS_MENU_FILE_GTK), NULL, NULL, 0, "<Branch>"},
|
||||
{(gchar *)GetString(STR_PREFS_ITEM_START_GTK), "<control>S", G_CALLBACK(cb_start), 0, NULL},
|
||||
{(gchar *)GetString(STR_PREFS_ITEM_SAVE_GTK), NULL, G_CALLBACK(cb_save), 0, NULL},
|
||||
{(gchar *)GetString(STR_PREFS_ITEM_ZAP_PRAM_GTK), NULL, G_CALLBACK(mn_zap_pram), 0, NULL},
|
||||
{(gchar *)GetString(STR_PREFS_ITEM_SEPL_GTK), NULL, NULL, 0, "<Separator>"},
|
||||
{(gchar *)GetString(STR_PREFS_ITEM_QUIT_GTK), "<control>Q", G_CALLBACK(cb_quit), 0, NULL},
|
||||
@ -1059,7 +1067,7 @@ static void create_graphics_pane(GtkWidget *top)
|
||||
}
|
||||
if (item >= 0)
|
||||
gtk_combo_box_set_active(GTK_COMBO_BOX(w_frameskip), item);
|
||||
g_signal_connect(combo, "changed", G_CALLBACK(mn_display), NULL);
|
||||
g_signal_connect(w_frameskip, "changed", G_CALLBACK(mn_frameskip), NULL);
|
||||
gtk_table_attach(GTK_TABLE(table), w_frameskip, 1, 2, 1, 2, (GtkAttachOptions)GTK_FILL, (GtkAttachOptions)0, 4, 4);
|
||||
|
||||
l_display_x = gtk_label_new(GetString(STR_DISPLAY_X_CTRL));
|
||||
|
@ -62,6 +62,7 @@ user_string_def platform_strings[] = {
|
||||
|
||||
{STR_PREFS_MENU_FILE_GTK, "/_File"},
|
||||
{STR_PREFS_ITEM_START_GTK, "/File/_Start Basilisk II"},
|
||||
{STR_PREFS_ITEM_SAVE_GTK, "/File/Save _Preferences"},
|
||||
{STR_PREFS_ITEM_ZAP_PRAM_GTK, "/File/_Zap PRAM File"},
|
||||
{STR_PREFS_ITEM_SEPL_GTK, "/File/sepl"},
|
||||
{STR_PREFS_ITEM_QUIT_GTK, "/File/_Quit Basilisk II"},
|
||||
|
@ -53,6 +53,7 @@ enum {
|
||||
|
||||
STR_PREFS_MENU_FILE_GTK,
|
||||
STR_PREFS_ITEM_START_GTK,
|
||||
STR_PREFS_ITEM_SAVE_GTK,
|
||||
STR_PREFS_ITEM_ZAP_PRAM_GTK,
|
||||
STR_PREFS_ITEM_SEPL_GTK,
|
||||
STR_PREFS_ITEM_QUIT_GTK,
|
||||
|
@ -355,6 +355,13 @@ static void window_destroyed(void)
|
||||
gtk_main_quit();
|
||||
}
|
||||
|
||||
// "Save" button clicked
|
||||
static void cb_save(...)
|
||||
{
|
||||
read_settings();
|
||||
SavePrefs();
|
||||
}
|
||||
|
||||
// "Start" button clicked
|
||||
static void cb_start(...)
|
||||
{
|
||||
@ -411,6 +418,7 @@ static void mn_zap_pram(...)
|
||||
static GtkItemFactoryEntry menu_items[] = {
|
||||
{(gchar *)GetString(STR_PREFS_MENU_FILE_GTK), NULL, NULL, 0, "<Branch>"},
|
||||
{(gchar *)GetString(STR_PREFS_ITEM_START_GTK), "<control>S", G_CALLBACK(cb_start), 0, NULL},
|
||||
{(gchar *)GetString(STR_PREFS_ITEM_SAVE_GTK), NULL, G_CALLBACK(cb_save), 0, NULL},
|
||||
{(gchar *)GetString(STR_PREFS_ITEM_ZAP_PRAM_GTK), NULL, G_CALLBACK(mn_zap_pram), 0, NULL},
|
||||
{(gchar *)GetString(STR_PREFS_ITEM_SEPL_GTK), NULL, NULL, 0, "<Separator>"},
|
||||
{(gchar *)GetString(STR_PREFS_ITEM_QUIT_GTK), "<control>Q", G_CALLBACK(cb_quit), 0, NULL},
|
||||
@ -946,7 +954,7 @@ static void create_graphics_pane(GtkWidget *top)
|
||||
}
|
||||
if (item >= 0)
|
||||
gtk_combo_box_set_active(GTK_COMBO_BOX(w_frameskip), item);
|
||||
g_signal_connect(combo, "changed", G_CALLBACK(mn_frameskip), NULL);
|
||||
g_signal_connect(w_frameskip, "changed", G_CALLBACK(mn_frameskip), NULL);
|
||||
gtk_table_attach(GTK_TABLE(table), w_frameskip, 1, 2, 1, 2, (GtkAttachOptions)GTK_FILL, (GtkAttachOptions)0, 4, 4);
|
||||
|
||||
l_display_x = gtk_label_new(GetString(STR_DISPLAY_X_CTRL));
|
||||
|
@ -64,6 +64,7 @@ user_string_def platform_strings[] = {
|
||||
{STR_KEYCODE_VENDOR_WARN, "Cannot find vendor '%s' in keycode translation file %s."},
|
||||
{STR_PREFS_MENU_FILE_GTK, "/_File"},
|
||||
{STR_PREFS_ITEM_START_GTK, "/File/_Start SheepShaver"},
|
||||
{STR_PREFS_ITEM_SAVE_GTK, "/File/Save _Preferences"},
|
||||
{STR_PREFS_ITEM_ZAP_PRAM_GTK, "/File/_Zap PRAM File"},
|
||||
{STR_PREFS_ITEM_SEPL_GTK, "/File/sepl"},
|
||||
{STR_PREFS_ITEM_QUIT_GTK, "/File/_Quit SheepShaver"},
|
||||
|
@ -58,6 +58,7 @@ enum {
|
||||
|
||||
STR_PREFS_MENU_FILE_GTK,
|
||||
STR_PREFS_ITEM_START_GTK,
|
||||
STR_PREFS_ITEM_SAVE_GTK,
|
||||
STR_PREFS_ITEM_ZAP_PRAM_GTK,
|
||||
STR_PREFS_ITEM_SEPL_GTK,
|
||||
STR_PREFS_ITEM_QUIT_GTK,
|
||||
|
Loading…
Reference in New Issue
Block a user