From: H.G. Muller Date: Mon, 29 Oct 2012 18:46:27 +0000 (+0100) Subject: Pay attention to NO_CANCEL dialog flag X-Git-Url: http://winboard.nl/cgi-bin?a=commitdiff_plain;h=7d7c05d2ca68bdd6cc55fc78a1a29c6635790987;p=xboard.git Pay attention to NO_CANCEL dialog flag --- diff --git a/gtk/xoptions.c b/gtk/xoptions.c index 5f4711f..d5ade4c 100644 --- a/gtk/xoptions.c +++ b/gtk/xoptions.c @@ -1492,9 +1492,12 @@ printf("n=%d, h=%d, w=%d\n",n,height,width); gtk_widget_show_all( dialog ); /* hide OK/cancel buttons */ - if((option[i].min & 2)) { + if((option[i].min & NO_OK)) { actionarea = gtk_dialog_get_action_area(GTK_DIALOG(dialog)); gtk_widget_hide(actionarea); + } else if((option[i].min & NO_CANCEL)) { + button = gtk_dialog_get_widget_for_response(GTK_DIALOG(dialog), GTK_RESPONSE_REJECT); + gtk_widget_hide(button); } g_signal_connect (dialog, "response",