Author: btami
Date: 2006-03-10 12:19:13 -0600 (Fri, 10 Mar 2006)
New Revision: 8217
Modified:
trunk/gnue-forms/src/GFObjects/GFBlock.py
Log:
fix for win32-driver: Scrollbar duplicates first record (Issue 16)
Modified: trunk/gnue-forms/src/GFObjects/GFBlock.py
===================================================================
--- trunk/gnue-forms/src/GFObjects/GFBlock.py 2006-03-10 18:03:23 UTC (rev
8216)
+++ trunk/gnue-forms/src/GFObjects/GFBlock.py 2006-03-10 18:19:13 UTC (rev
8217)
@@ -583,7 +583,7 @@
"""
Scroll the given number of records.
"""
-
+
self.scrollToRecord (self.__visibleStart + adjustment)
@@ -596,7 +596,12 @@
Scrolls the block to the given position.
The record number given in position will become the first visible record.
- """
+ """
+
+ if position < 0:
+ position = 0
+ elif position > self._resultSet.getRecordCount() - self._rows:
+ position = self._resultSet.getRecordCount() - self._rows
# First, scroll as far as possible without moving the record pointer
newVisibleStart = position
_______________________________________________
Commit-gnue mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/commit-gnue