SWF-1018 - Update SelectionAware interface to make currentRowSelected a proper JavaBean property

This commit is contained in:
Jeremy Grelle
2009-01-14 20:50:03 +00:00
parent 9c1d461bd4
commit d45f45768f
4 changed files with 4 additions and 4 deletions

View File

@@ -53,7 +53,7 @@ public class ManySelectionTrackingListDataModel extends SerializableListDataMode
selections.addAll((List) getWrappedData());
}
public void setSelected(boolean rowSelected) {
public void setCurrentRowSelected(boolean rowSelected) {
if (!isRowAvailable()) {
return;
}

View File

@@ -63,7 +63,7 @@ public class OneSelectionTrackingListDataModel extends SerializableListDataModel
}
}
public void setSelected(boolean rowSelected) {
public void setCurrentRowSelected(boolean rowSelected) {
if (!isRowAvailable()) {
return;
}

View File

@@ -36,7 +36,7 @@ public interface SelectionAware {
* Sets whether the row pointed to by the model's current index is selected
* @param rowSelected true to select the current row
*/
public void setSelected(boolean rowSelected);
public void setCurrentRowSelected(boolean rowSelected);
/**
* Sets the list of selected row data objects for the model.

View File

@@ -64,7 +64,7 @@ public class SelectionTrackingActionListener implements ActionListener {
if (valueAccessor != null) {
Object value = ReflectionUtils.invokeMethod(valueAccessor, parent);
if (value != null && value instanceof SelectionAware) {
((SelectionAware) value).setSelected(true);
((SelectionAware) value).setCurrentRowSelected(true);
if (logger.isDebugEnabled()) {
logger.debug("Row selection has been set on the current SelectionAware data model.");
}