propertyModel.addRow(new PropertyTableRow(key));
modified = true;
}
((Dialog) source.getParentWidgetByClass(Dialog.class)).dispose();
} catch (Exception e) {
new MessageDialog(e);
}
}
}, new MapDataModel());
dialog.initDialog(frame);
dialog.show();
} else if (name.equals("popup")) {
PopupMenu popup = (PopupMenu) constructWidget("PropertyPopup");
popup.popup(event);
} else if (name.equals("delete")) {
TableRow rows[] = (TableRow[]) dataModel.getValue("property.value");
for (int i = 0; i < rows.length; i++) {
PropertyTableRow row = (PropertyTableRow) rows[i];
propertyModel.removeRow(row);
properties.remove(row.getValue("key"));
}
} else if (name.equals("clear")) {
dataModel.setValue("property.value", new TableRow[] {
});
propertyModel.clear();
properties.clear();
} else if (name.equals("import")) {
File file = DialogUtils.showOpenFileDialog(frame, "properties");
if (file != null) {
properties.load(new FileInputStream(file));
buildModel();
}
} else if (name.equals("save")) {
doSave();
} else if (name.equals("refresh")) {
widgetTree.refreshInternationalProperties();
}
} catch (Exception e) {
new MessageDialog(e);
}
}