41 if (arg == GTK_RESPONSE_YES) {
54 GtkWidget *dialog, *label;
57 dialog = gtk_dialog_new_with_buttons(
_(
"Preferred soundset"),
62 _(
"_Keep current soundset"),
66 gtk_dialog_set_default_response(GTK_DIALOG(dialog), GTK_RESPONSE_YES);
67 gtk_window_set_destroy_with_parent(GTK_WINDOW(dialog),
TRUE);
70 _(
"Modpack suggests using %s soundset.\n"
71 "It might not work with other soundsets.\n"
72 "You are currently using soundset %s."),
75 label = gtk_label_new(buf);
76 gtk_box_append(GTK_BOX(gtk_dialog_get_content_area(GTK_DIALOG(dialog))), label);
77 gtk_label_set_justify(GTK_LABEL(label), GTK_JUSTIFY_CENTER);
78 gtk_widget_show(label);
85 gtk_window_destroy(GTK_WINDOW(dialog));
93 if (arg == GTK_RESPONSE_YES) {
105 GtkWidget *dialog, *label;
108 dialog = gtk_dialog_new_with_buttons(
_(
"Preferred musicset"),
113 _(
"_Keep current musicset"),
116 gtk_dialog_set_default_response(GTK_DIALOG(dialog), GTK_RESPONSE_YES);
117 gtk_window_set_destroy_with_parent(GTK_WINDOW(dialog),
TRUE);
120 _(
"Modpack suggests using %s musicset.\n"
121 "It might not work with other musicsets.\n"
122 "You are currently using musicset %s."),
125 label = gtk_label_new(buf);
126 gtk_box_append(GTK_BOX(gtk_dialog_get_content_area(GTK_DIALOG(dialog))), label);
127 gtk_label_set_justify(GTK_LABEL(label), GTK_JUSTIFY_CENTER);
128 gtk_widget_show(label);
135 gtk_window_destroy(GTK_WINDOW(dialog));
void audio_restart(const char *soundset_name, const char *musicset_name)
void setup_dialog(GtkWidget *shell, GtkWidget *parent)
void popup_musicset_suggestion_dialog(void)
void popup_soundset_suggestion_dialog(void)
gint blocking_dialog(GtkWidget *dlg)
static void soundset_suggestion_response(gint arg)
static void musicset_suggestion_response(gint arg)
struct packet_ruleset_control control
char preferred_soundset[MAX_LEN_NAME]
char preferred_musicset[MAX_LEN_NAME]
int fc_snprintf(char *str, size_t n, const char *format,...)