if (MessageDialog.openConfirm(getShell(), "Confirm", "Are you sure you want to remove "
+ selection.size()
+ " selected element(s)?")) {
for (Object element : selection) {
if (element instanceof CategoryInfo) {
commands_add(new CategoryRemoveCommand((CategoryInfo) element));
} else if (element instanceof DeviceInfo) {
commands_add(new DeviceRemoveCommand((DeviceInfo) element));
}
}
refreshViewer();