category.setValueMap(catValueMap);
category.setValueIcons(catIconsMap);
category.setShowIcons(true);
StaticTextItem oldFile = new StaticTextItem("oldFile", MSG.view_drift_table_oldFile());
FormItem oldFileLink = null;
StaticTextItem newFile = new StaticTextItem("newFile", MSG.view_drift_table_newFile());
FormItem newFileLink = null;
if (driftDetails.isBinaryFile()) {
switch (driftDetails.getDrift().getCategory()) {
case FILE_ADDED:
category.setValue(DriftDataSource.CATEGORY_ICON_ADD);
oldFile.setValue(MSG.common_label_none());
oldFileLink = spacer;
newFile.setValue(driftDetails.getDrift().getNewDriftFile().getHashId());
newFileLink = spacer;
break;
case FILE_CHANGED:
category.setValue(DriftDataSource.CATEGORY_ICON_CHANGE);
oldFile.setValue(driftDetails.getDrift().getOldDriftFile().getHashId());
oldFileLink = spacer;
newFile.setValue(driftDetails.getDrift().getNewDriftFile().getHashId());
newFileLink = spacer;
break;
case FILE_REMOVED:
category.setValue(DriftDataSource.CATEGORY_ICON_REMOVE);
oldFile.setValue(driftDetails.getDrift().getOldDriftFile().getHashId());
oldFileLink = spacer;
newFile.setValue(MSG.common_label_none());
newFileLink = spacer;
break;
}
driftForm.setItems(id, spacer, path, spacer, category, spacer, timestamp, spacer, oldFile, oldFileLink,
newFile, newFileLink);
} else {
FormItem viewDiffLink = spacer;
switch (driftDetails.getDrift().getCategory()) {
case FILE_ADDED:
category.setValue(DriftDataSource.CATEGORY_ICON_ADD);
oldFile.setValue(MSG.common_label_none());
oldFileLink = spacer;