File tree Expand file tree Collapse file tree 2 files changed +22
-5
lines changed
Expand file tree Collapse file tree 2 files changed +22
-5
lines changed Original file line number Diff line number Diff line change 7171 </child >
7272
7373 <child >
74- <object class =" GtkInfoBar" id =" error_bar" >
75- <property name =" message-type" >error</property >
76- <property name =" show-close-button" >true</property >
74+ <object class =" GtkActionBar" id =" error_bar" >
7775 <property name =" revealed" >false</property >
7876
79- <child >
77+ <child type = " center " >
8078 <object class =" GtkLabel" id =" error_label" >
79+ <property name =" hexpand" >true</property >
80+ <property name =" ellipsize" >middle</property >
81+ <property name =" xalign" >0.0</property >
8182 <attributes >
8283 <attribute name =" weight" value =" bold" />
8384 </attributes >
85+
86+ </object >
87+ </child >
88+
89+ <child type =" end" >
90+ <object class =" GtkButton" >
91+ <property name =" label" >OK</property >
92+ <signal name =" clicked" handler =" save_options_error_clicked" />
8493 </object >
8594 </child >
95+
8696 </object >
8797 </child >
8898
Original file line number Diff line number Diff line change @@ -89,7 +89,13 @@ save_options_error(SaveOptions *options)
8989 err [i - 1 ] = '\0' ;
9090 gtk_label_set_text (GTK_LABEL (options -> error_label ), err );
9191
92- gtk_info_bar_set_revealed (GTK_INFO_BAR (options -> error_bar ), TRUE);
92+ gtk_action_bar_set_revealed (GTK_ACTION_BAR (options -> error_bar ), TRUE);
93+ }
94+
95+ static void
96+ save_options_error_clicked (GtkButton * button , SaveOptions * options )
97+ {
98+ gtk_action_bar_set_revealed (GTK_ACTION_BAR (options -> error_bar ), FALSE);
9399}
94100
95101static void
@@ -364,6 +370,7 @@ save_options_class_init(SaveOptionsClass *class)
364370 BIND_VARIABLE (SaveOptions , title );
365371
366372 BIND_CALLBACK (save_options_cancel_clicked );
373+ BIND_CALLBACK (save_options_error_clicked );
367374}
368375
369376/* This function is used by:
You can’t perform that action at this time.
0 commit comments