AUDIT: r20481 - gnucash/trunk/src - Bug #645640: Online transfer must not allow to change amount in second window

Christian Stimming cstim at code.gnucash.org
Fri Mar 25 17:19:01 EDT 2011


Author: cstim
Date: 2011-03-25 17:19:01 -0400 (Fri, 25 Mar 2011)
New Revision: 20481
Trac: http://svn.gnucash.org/trac/changeset/20481

Modified:
   gnucash/trunk/src/gnome-utils/dialog-transfer.c
   gnucash/trunk/src/gnome-utils/dialog-transfer.h
   gnucash/trunk/src/import-export/aqbanking/gnc-ab-transfer.c
Log:
Bug #645640: Online transfer must not allow to change amount in second window

BP

Modified: gnucash/trunk/src/gnome-utils/dialog-transfer.c
===================================================================
--- gnucash/trunk/src/gnome-utils/dialog-transfer.c	2011-03-25 19:57:20 UTC (rev 20480)
+++ gnucash/trunk/src/gnome-utils/dialog-transfer.c	2011-03-25 21:19:01 UTC (rev 20481)
@@ -1176,6 +1176,12 @@
 
     gnc_amount_edit_set_amount (GNC_AMOUNT_EDIT (xferData->amount_edit), amount);
 }
+void gnc_xfer_dialog_set_amount_sensitive(XferDialog *xferData,
+                                          gboolean is_sensitive)
+{
+    g_assert(xferData);
+    gtk_widget_set_sensitive(gnc_amount_edit_gtk_entry(GNC_AMOUNT_EDIT (xferData->amount_edit)), is_sensitive);
+}
 
 
 /********************************************************************\

Modified: gnucash/trunk/src/gnome-utils/dialog-transfer.h
===================================================================
--- gnucash/trunk/src/gnome-utils/dialog-transfer.h	2011-03-25 19:57:20 UTC (rev 20480)
+++ gnucash/trunk/src/gnome-utils/dialog-transfer.h	2011-03-25 21:19:01 UTC (rev 20481)
@@ -99,6 +99,9 @@
  */
 void gnc_xfer_dialog_set_amount(XferDialog *xferData, gnc_numeric amount);
 
+/** Set the "sensitive" state of the amount field to the given value */
+void gnc_xfer_dialog_set_amount_sensitive(XferDialog *xferData, gboolean is_sensitive);
+
 /**
  *   set the description in the given xfer dialog
  *

Modified: gnucash/trunk/src/import-export/aqbanking/gnc-ab-transfer.c
===================================================================
--- gnucash/trunk/src/import-export/aqbanking/gnc-ab-transfer.c	2011-03-25 19:57:20 UTC (rev 20480)
+++ gnucash/trunk/src/import-export/aqbanking/gnc-ab-transfer.c	2011-03-25 21:19:01 UTC (rev 20481)
@@ -226,6 +226,7 @@
                      xaccAccountGetCommoditySCU(gnc_acc),
                      GNC_HOW_RND_ROUND_HALF_UP);
         gnc_xfer_dialog_set_amount(xfer_dialog, amount);
+        gnc_xfer_dialog_set_amount_sensitive(xfer_dialog, FALSE);
 
         description = gnc_ab_description_to_gnc(ab_trans);
         gnc_xfer_dialog_set_description(xfer_dialog, description);



More information about the gnucash-changes mailing list