[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gnue] r8740 - trunk/gnue-forms/src/GFObjects
From: |
reinhard |
Subject: |
[gnue] r8740 - trunk/gnue-forms/src/GFObjects |
Date: |
Tue, 10 Oct 2006 15:10:24 -0500 (CDT) |
Author: reinhard
Date: 2006-10-10 15:10:23 -0500 (Tue, 10 Oct 2006)
New Revision: 8740
Modified:
trunk/gnue-forms/src/GFObjects/GFField.py
trunk/gnue-forms/src/GFObjects/GFTabStop.py
Log:
If the foreign key resultset changes for a dropdown, update the UI for *all*
rows, not only for the current row.
Modified: trunk/gnue-forms/src/GFObjects/GFField.py
===================================================================
--- trunk/gnue-forms/src/GFObjects/GFField.py 2006-10-10 19:57:47 UTC (rev
8739)
+++ trunk/gnue-forms/src/GFObjects/GFField.py 2006-10-10 20:10:23 UTC (rev
8740)
@@ -326,9 +326,10 @@
# selected value.
if hasattr(self, '_GFField__fk_resultSet'):
self.__fk_resultSet.findRecord({self.fk_key: self.getValue()})
- # This will cause __refresh_ui() to be called via __dsCursorMoved
+ # This will cause __refresh_ui_current() to be called via
+ # __dsCursorMoved
else:
- self.__refresh_ui()
+ self.__refresh_ui_current()
# -------------------------------------------------------------------------
@@ -365,7 +366,7 @@
# The entry causing the fk record change has already posted a setValue
# for this field; our current record already contians the correct data.
# All we have to do is tell our UI to update.
- self.__refresh_ui()
+ self.__refresh_ui_current()
# -------------------------------------------------------------------------
@@ -398,6 +399,9 @@
# Remember the resultSet for later
self.__fk_resultSet = resultSet
+
+ # Update the UI to also for other rows
+ self.__refresh_ui_all()
assert gDebug(5,'Created for DropDown: %s' % self._allowedValues)
@@ -420,12 +424,19 @@
# Refresh the user interface with a changed field value
# -------------------------------------------------------------------------
- def __refresh_ui(self):
+ def __refresh_ui_current(self):
for entry in self._entryList:
entry.refresh_ui_current()
+ # -------------------------------------------------------------------------
+ def __refresh_ui_all(self):
+
+ for entry in self._entryList:
+ entry.refresh_ui_all()
+
+
# =========================================================================
# Trigger functions
# =========================================================================
Modified: trunk/gnue-forms/src/GFObjects/GFTabStop.py
===================================================================
--- trunk/gnue-forms/src/GFObjects/GFTabStop.py 2006-10-10 19:57:47 UTC (rev
8739)
+++ trunk/gnue-forms/src/GFObjects/GFTabStop.py 2006-10-10 20:10:23 UTC (rev
8740)
@@ -255,6 +255,15 @@
# -------------------------------------------------------------------------
+ # Refresh the user interface with the current field data for all rows
+ # -------------------------------------------------------------------------
+
+ def refresh_ui_all(self):
+
+ self.refresh_ui(0, self._rows - 1)
+
+
+ # -------------------------------------------------------------------------
# Refresh the user interface with the current field data
# -------------------------------------------------------------------------
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [gnue] r8740 - trunk/gnue-forms/src/GFObjects,
reinhard <=