use of net.sourceforge.processdash.ui.lib.binding.ErrorData in project processdash by dtuma.
the class BoundDefectData method updateDefects.
public void updateDefects() {
ErrorData error = form.getErrorDataForAttr("defects");
if (error != null) {
this.errorData = error;
setDefectData(Collections.EMPTY_LIST);
} else {
Object newValue = form.get("defects");
this.errorData = null;
if (newValue instanceof List)
setDefectData((List) newValue);
else
setDefectData(Collections.EMPTY_LIST);
}
}
use of net.sourceforge.processdash.ui.lib.binding.ErrorData in project processdash by dtuma.
the class BoundDefectTable method resyncTable.
private void resyncTable() {
selectAll.setSelected(true);
TableColumnModel tcm = new DefaultTableColumnModel();
for (int col = 0; col < data.getColumnCount(); col++) if (data.hasData(col))
tcm.addColumn(tableColumns[col]);
table.setColumnModel(tcm);
ErrorData error = data.getErrorData();
if (error != null) {
messageLabel.setText(error.getError());
messageLabel.setForeground(map.getErrorColor(error));
cardLayout.first(this);
} else {
messageLabel.setText(null);
cardLayout.last(this);
}
}
Aggregations