r18024 - gnucash/trunk/src/register/register-gnome - Register: Force scroll to the current row if the row height may have changed and pushed the current row out of sight.

Charles Day cedayiv at code.gnucash.org
Mon Apr 6 13:00:04 EDT 2009


Author: cedayiv
Date: 2009-04-06 13:00:03 -0400 (Mon, 06 Apr 2009)
New Revision: 18024
Trac: http://svn.gnucash.org/trac/changeset/18024

Modified:
   gnucash/trunk/src/register/register-gnome/gnucash-sheet.c
Log:
Register: Force scroll to the current row if the row height may have changed and pushed the current row out of sight.


Modified: gnucash/trunk/src/register/register-gnome/gnucash-sheet.c
===================================================================
--- gnucash/trunk/src/register/register-gnome/gnucash-sheet.c	2009-04-06 16:27:21 UTC (rev 18023)
+++ gnucash/trunk/src/register/register-gnome/gnucash-sheet.c	2009-04-06 17:00:03 UTC (rev 18024)
@@ -1111,6 +1111,18 @@
 
         gnc_item_edit_configure (GNC_ITEM_EDIT(sheet->item_editor));
         gnucash_sheet_update_adjustments (sheet);
+
+        if (sheet->table)
+	{
+                VirtualLocation virt_loc;
+
+                virt_loc = sheet->table->current_cursor_loc;
+
+                if (gnucash_sheet_cell_valid (sheet, virt_loc))
+                        gnucash_sheet_show_row (sheet,
+                                                virt_loc.vcell_loc.virt_row);
+        }
+
 	LEAVE(" ");
 }
 



More information about the gnucash-changes mailing list