/** * Returns the description of the given configuration type * in the current mode or <code>null</code> if none. * * @param configType the config type * @return the description of the given configuration type or <code>null</code> */ private String getDescription(ILaunchConfigurationType configType) { String description = null; if(configType != null) { String mode = fDialog.getMode(); description = LaunchConfigurationPresentationManager.getDefault().getDescription(configType, mode); } if (description == null) { description = IInternalDebugCoreConstants.EMPTY_STRING; } return description; }
/** * Returns the listing of modes for the current config * @return the listing of modes for the current config * @since 3.3 */ private Set<String> getCurrentModeSet() { Set<String> set = new HashSet<>(); ILaunchConfigurationWorkingCopy config = getWorkingCopy(); if(config != null) { try { set.addAll(config.getModes()); set.add(getLaunchConfigurationDialog().getMode()); } catch(CoreException ce) {DebugUIPlugin.log(ce);} } return set; }
if(!canLaunchWithModes()) { SelectLaunchModesDialog sld = new SelectLaunchModesDialog(getShell(), getLaunchConfigurationDialog().getMode(), getWorkingCopy()); if(sld.open() == IDialogConstants.OK_ID) { @SuppressWarnings("unchecked") Set<String> modes = (Set<String>) res[0]; modes.remove(getLaunchConfigurationDialog().getMode()); ILaunchConfigurationWorkingCopy wc = getWorkingCopy(); wc.setModes(modes); getWorkingCopy().getType().getDelegates(getCurrentModeSet()), getWorkingCopy(), getLaunchConfigurationDialog().getMode()); if(sldd.open() == IDialogConstants.OK_ID) { displayInstanceTabs(true);
/** * Sets the default values for the given {@link LaunchConfigurationWorkingCopy} * @param wc * @since 3.6 */ protected void doSetDefaults(ILaunchConfigurationWorkingCopy wc) { try { ILaunchConfigurationTabGroup tabGroup = LaunchConfigurationPresentationManager.getDefault().getTabGroup(wc, getMode()); // this only works because this action is only present when the dialog is open ILaunchConfigurationDialog dialog = LaunchConfigurationsDialog.getCurrentlyVisibleLaunchConfigurationDialog(); tabGroup.createTabs(dialog, dialog.getMode()); ILaunchConfigurationTab[] tabs = tabGroup.getTabs(); for (int i = 0; i < tabs.length; i++) { tabs[i].setLaunchConfigurationDialog(dialog); } tabGroup.setDefaults(wc); tabGroup.dispose(); } catch (CoreException e) { DebugUIPlugin.log(e.getStatus()); } }
/** * Dialog to Show the Command line */ protected void handleShowCommandLinePressed() { boolean showCommandLineDialog = true; if (isDirty()) { int returnVal = showSaveChangesDialog(); if (returnVal == IDialogConstants.YES_ID) { handleApplyPressed(); } else if (returnVal == IDialogConstants.NO_ID) { handleRevertPressed(); } else { showCommandLineDialog = false; } } if (showCommandLineDialog) { ShowCommandLineDialog dialog = new ShowCommandLineDialog(getShell(), getLaunchConfigurationDialog().getMode(), fWorkingCopy); dialog.open(); } }
try { tabGroup = LaunchConfigurationPresentationManager.getDefault().getTabGroup(getWorkingCopy(), getLaunchConfigurationDialog().getMode()); finalArray[0] = tabGroup; } catch (CoreException ce) { return; tabGroup.createTabs(getLaunchConfigurationDialog(), getLaunchConfigurationDialog().getMode()); ILaunchConfigurationTab[] tabs = tabGroup.getTabs(); for (int i = 0; i < tabs.length; i++) {
tabGroup.createTabs(dialog, dialog.getMode()); ILaunchConfigurationTab[] tabs = tabGroup.getTabs(); for (int i = 0; i < tabs.length; i++) {
tabGroup.createTabs(dialog, dialog.getMode()); ILaunchConfigurationTab[] tabs = tabGroup.getTabs(); for (int i = 0; i < tabs.length; i++) {