*/
public class CdmViewerChooser extends PopupDialog implements ISelectionChangedListener, ILabelProvider{
- private Map<String, String> nameViewerMap;
+ private Map<Command, String> nameViewerMap;
private Object input;
public CdmViewerChooser(Shell parentShell) {
//if only one editor is available then open it
if(nameViewerMap.size()==1){
- String commandId = nameViewerMap.keySet().iterator().next();
- executeCommand(commandId, input);
+ Command command = nameViewerMap.keySet().iterator().next();
+ executeCommand(command.getId(), input);
}
else{
if(nameViewerMap.isEmpty()){