[Gnucash-changes] r12951 - gnucash/trunk - Add an icon to the export button in the generic filename dialog.

David Hampton hampton at cvs.gnucash.org
Mon Jan 23 00:42:28 EST 2006


Author: hampton
Date: 2006-01-23 00:42:27 -0500 (Mon, 23 Jan 2006)
New Revision: 12951
Trac: http://svn.gnucash.org/trac/changeset/12951

Modified:
   gnucash/trunk/ChangeLog
   gnucash/trunk/src/gnome-utils/gnc-file.c
Log:
Add an icon to the export button in the generic filename dialog.


Modified: gnucash/trunk/ChangeLog
===================================================================
--- gnucash/trunk/ChangeLog	2006-01-23 04:36:24 UTC (rev 12950)
+++ gnucash/trunk/ChangeLog	2006-01-23 05:42:27 UTC (rev 12951)
@@ -1,5 +1,8 @@
 2006-01-22  David Hampton  <hampton at employees.org>
 
+	* src/gnome-utils/gnc-file.c: Add an icon to the export button in
+	the generic filename dialog.
+
 	* src/gnome-utils/glade/commodity.glade:
 	* src/gnome/dialog-price-editor.c:
 	* src/gnome/glade/progress.glade:

Modified: gnucash/trunk/src/gnome-utils/gnc-file.c
===================================================================
--- gnucash/trunk/src/gnome-utils/gnc-file.c	2006-01-23 04:36:24 UTC (rev 12950)
+++ gnucash/trunk/src/gnome-utils/gnc-file.c	2006-01-23 05:42:27 UTC (rev 12951)
@@ -81,6 +81,7 @@
   const char *internal_name;
   char *file_name = NULL;
   gchar * okbutton = GTK_STOCK_OPEN;
+  const gchar *ok_icon = NULL;
   GtkFileChooserAction action = GTK_FILE_CHOOSER_ACTION_OPEN; 
   gint response;
 
@@ -108,6 +109,7 @@
 	case GNC_FILE_DIALOG_EXPORT:
 		  action = GTK_FILE_CHOOSER_ACTION_SAVE;
 		  okbutton = _("_Export");
+		  ok_icon = GTK_STOCK_CONVERT;
 		  if (title == NULL)
 			  title = _("Export");
 		  break;
@@ -119,8 +121,12 @@
 			  NULL,
 			  action,
 			  GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL,
-			  okbutton, GTK_RESPONSE_ACCEPT,
 			  NULL);
+  if (ok_icon)
+    gnc_gtk_dialog_add_button(file_box, okbutton, ok_icon, GTK_RESPONSE_ACCEPT);
+  else
+    gtk_dialog_add_button(GTK_DIALOG(file_box),
+			  okbutton, GTK_RESPONSE_ACCEPT);
 
   if (starting_dir) {
     gchar *dir_name;



More information about the gnucash-changes mailing list