* Row content not updated after exit edit mode

Link to SF Tracker: http://sourceforge.net/support/tracker.php?aid=2921253
This commit is contained in:
Heng Sin Low 2009-12-26 04:22:27 +00:00
parent 9d2097d2eb
commit 6052138311
1 changed files with 13 additions and 1 deletions

View File

@ -419,7 +419,13 @@ public class GridPanel extends Borderlayout implements EventListener
if (!isRowRendered(row, pgIndex)) { if (!isRowRendered(row, pgIndex)) {
listbox.renderRow(row); listbox.renderRow(row);
} else { } else {
Row old = renderer.getCurrentRow();
int oldIndex = renderer.getCurrentRowIndex();
renderer.setCurrentRow(row); renderer.setCurrentRow(row);
if (old != null && old != row && oldIndex >= 0 && oldIndex != gridTab.getCurrentRow())
{
listModel.updateComponent(oldIndex % pageSize);
}
} }
if (modeless && !renderer.isEditing()) { if (modeless && !renderer.isEditing()) {
renderer.editCurrentRow(); renderer.editCurrentRow();
@ -437,7 +443,13 @@ public class GridPanel extends Borderlayout implements EventListener
if (!isRowRendered(row, rowIndex)) { if (!isRowRendered(row, rowIndex)) {
listbox.renderRow(row); listbox.renderRow(row);
} else { } else {
Row old = renderer.getCurrentRow();
int oldIndex = renderer.getCurrentRowIndex();
renderer.setCurrentRow(row); renderer.setCurrentRow(row);
if (old != null && old != row && oldIndex >= 0 && oldIndex != gridTab.getCurrentRow())
{
listModel.updateComponent(oldIndex);
}
} }
if (modeless && !renderer.isEditing()) { if (modeless && !renderer.isEditing()) {
renderer.editCurrentRow(); renderer.editCurrentRow();