protected void persistChanges() {
IFeatureSite site = getSite();
if( site == null ){
return;
}
EditFeature feature = site.getEditFeature();
if (name != null && !name.isDisposed() && Boolean.TRUE.equals(name.getData(DIRTY))) {
feature.setAttribute(this.NAME, name.getText());
}
if (gmiCntry != null && !gmiCntry.isDisposed()
&& Boolean.TRUE.equals(gmiCntry.getData(DIRTY))) {
feature.setAttribute(this.GMI_CNTRY, gmiCntry.getText());
}
if (colorMap != null && !colorMap.getCombo().isDisposed()
&& Boolean.TRUE.equals(colorMap.getData(DIRTY))) {
IStructuredSelection selection = (IStructuredSelection) colorMap.getSelection();
Integer color = (Integer) selection.getFirstElement();
feature.setAttribute(COLOR_MAP, color.toString());
}
}