mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-01-25 01:02:24 +00:00
Make the GTK font setup error box non-modal.
That was the last (in fact, the only) call to the modal version of message_box() outside gtkdlg.c, so I can remove it from the header file.
This commit is contained in:
parent
8b0d460578
commit
71ed04dbc3
@ -1084,7 +1084,7 @@ static void set_transient_window_pos(GtkWidget *parent, GtkWidget *child)
|
||||
#endif
|
||||
}
|
||||
|
||||
static void trivial_post_dialog_fn(void *vctx, int result)
|
||||
void trivial_post_dialog_fn(void *vctx, int result)
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -4167,10 +4167,10 @@ static void after_change_settings_dialog(void *vctx, int retval)
|
||||
char *msgboxtext =
|
||||
dupprintf("Could not change fonts in terminal window: %s\n",
|
||||
errmsg);
|
||||
message_box(inst->window, "Font setup error", msgboxtext,
|
||||
string_width("Could not change fonts in terminal"
|
||||
" window:"),
|
||||
FALSE, &buttons_ok);
|
||||
create_message_box(
|
||||
inst->window, "Font setup error", msgboxtext,
|
||||
string_width("Could not change fonts in terminal window:"),
|
||||
FALSE, &buttons_ok, trivial_post_dialog_fn, NULL);
|
||||
sfree(msgboxtext);
|
||||
sfree(errmsg);
|
||||
} else {
|
||||
|
@ -122,8 +122,9 @@ unsigned long getticks(void);
|
||||
/* The per-session frontend structure managed by gtkwin.c */
|
||||
struct gui_data;
|
||||
|
||||
/* Callback when a dialog box finishes */
|
||||
/* Callback when a dialog box finishes, and a no-op implementation of it */
|
||||
typedef void (*post_dialog_fn_t)(void *ctx, int result);
|
||||
void trivial_post_dialog_fn(void *vctx, int result);
|
||||
|
||||
/* Start up a session window, with or without a preliminary config box */
|
||||
void initial_config_box(Conf *conf, post_dialog_fn_t after, void *afterctx);
|
||||
@ -189,9 +190,6 @@ GtkWidget *create_message_box(
|
||||
GtkWidget *parentwin, const char *title, const char *msg, int minwid,
|
||||
int selectable, const struct message_box_buttons *buttons,
|
||||
post_dialog_fn_t after, void *afterctx);
|
||||
int message_box(
|
||||
GtkWidget *parentwin, const char *title, const char *msg, int minwid,
|
||||
int selectable, const struct message_box_buttons *buttons);
|
||||
#endif
|
||||
|
||||
/* Things pterm.c needs from {ptermm,uxputty}.c */
|
||||
|
Loading…
Reference in New Issue
Block a user