[gnumeric] solver: fix options tab.



commit 58a9fa8143fd4ff98f8bba40d773bb23f21ff2bb
Author: Morten Welinder <terra gnome org>
Date:   Thu May 27 19:06:53 2010 -0400

    solver: fix options tab.

 src/dialogs/ChangeLog       |   12 ++++++++----
 src/dialogs/dialog-solver.c |   14 ++++----------
 2 files changed, 12 insertions(+), 14 deletions(-)
---
diff --git a/src/dialogs/ChangeLog b/src/dialogs/ChangeLog
index bd4ebd5..2b71c9c 100644
--- a/src/dialogs/ChangeLog
+++ b/src/dialogs/ChangeLog
@@ -1,17 +1,21 @@
+2010-05-27  Morten Welinder  <terra gnome org>
+
+	* dialog-solver.c (dialog_init): Fix setting of spin buttons.
+
 2010-05-26 Andreas J. Guelzow <aguelzow pyrshep ca>
 	for Sameer Morar <smorar gmail com>
 
 	*  print.glade: minor adjustments
-	
+
 2010-05-25 Andreas J. Guelzow <aguelzow pyrshep ca>
 
-	* dialog-printer-setup.c (MarginPreviewPageAvailableSize): 
+	* dialog-printer-setup.c (MarginPreviewPageAvailableSize):
 	  change uint to guint
 	(margin_preview_page_available_size): ditto
-	
+
 2010-05-24 Andreas J. Guelzow <aguelzow pyrshep ca>
 	for Sameer Morar <smorar gmail com>
-	
+
 	* print.glade: add GtkAlignment to margin preview to center it
 	* dialog-printer-setup.c (margin_preview_page_available_size):
 	  create function to determine the available page size based upon
diff --git a/src/dialogs/dialog-solver.c b/src/dialogs/dialog-solver.c
index f76b37f..80d4d9a 100644
--- a/src/dialogs/dialog-solver.c
+++ b/src/dialogs/dialog-solver.c
@@ -1006,19 +1006,13 @@ dialog_init (SolverState *state)
 	/* Options */
 	state->max_iter_entry = glade_xml_get_widget (state->gui,
 						      "max_iter_entry");
-	{
-		char *txt = g_strdup_printf ("%d", param->options.max_iter);
-		gtk_entry_set_text (GTK_ENTRY (state->max_iter_entry), txt);
-		g_free (txt);
-	}
+	gtk_spin_button_set_value (GTK_SPIN_BUTTON (state->max_iter_entry),
+				   param->options.max_iter);
 
 	state->max_time_entry = glade_xml_get_widget (state->gui,
 						      "max_time_entry");
-	{
-		char *txt = g_strdup_printf ("%d", param->options.max_time_sec);
-		gtk_entry_set_text (GTK_ENTRY (state->max_time_entry), txt);
-		g_free (txt);
-	}
+	gtk_spin_button_set_value (GTK_SPIN_BUTTON (state->max_time_entry),
+				   param->options.max_time_sec);
 
 /* lhs_entry */
 	table = GTK_TABLE (glade_xml_get_widget (state->gui, "edit-table"));



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]