mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-09-10 03:53:21 +02:00
launch-bar: config selector - remove active config chage
in last patch I did not actually remove setting active config from configSelector - it should not set it, but it will be set automatically when config is saved. Change-Id: Idcb84d2d71567f1e60cb452fb4df15ed962dded6
This commit is contained in:
parent
17fff835d1
commit
baa294b085
1 changed files with 5 additions and 5 deletions
|
@ -17,7 +17,6 @@ import org.eclipse.core.runtime.IProgressMonitor;
|
||||||
import org.eclipse.core.runtime.IStatus;
|
import org.eclipse.core.runtime.IStatus;
|
||||||
import org.eclipse.core.runtime.Status;
|
import org.eclipse.core.runtime.Status;
|
||||||
import org.eclipse.core.runtime.jobs.Job;
|
import org.eclipse.core.runtime.jobs.Job;
|
||||||
import org.eclipse.debug.core.ILaunchConfiguration;
|
|
||||||
import org.eclipse.jface.viewers.ILabelProvider;
|
import org.eclipse.jface.viewers.ILabelProvider;
|
||||||
import org.eclipse.jface.viewers.IStructuredContentProvider;
|
import org.eclipse.jface.viewers.IStructuredContentProvider;
|
||||||
import org.eclipse.jface.viewers.LabelProvider;
|
import org.eclipse.jface.viewers.LabelProvider;
|
||||||
|
@ -199,11 +198,12 @@ public class ConfigSelector extends CSelector {
|
||||||
new Job("Create Launch Configuration") {
|
new Job("Create Launch Configuration") {
|
||||||
protected IStatus run(IProgressMonitor monitor) {
|
protected IStatus run(IProgressMonitor monitor) {
|
||||||
try {
|
try {
|
||||||
ILaunchConfiguration config = wizard.getWorkingCopy().doSave();
|
|
||||||
final LaunchBarManager barManager = uiManager.getManager();
|
final LaunchBarManager barManager = uiManager.getManager();
|
||||||
final ILaunchDescriptor desc = barManager.getDefaultDescriptorType().getDescriptor(config);
|
final ILaunchDescriptor desc = barManager.getDefaultDescriptorType().getDescriptor(wizard.getWorkingCopy());
|
||||||
barManager.setLaunchMode(desc, wizard.getLaunchMode());
|
if (desc != null) {
|
||||||
barManager.setActiveLaunchDescriptor(desc);
|
barManager.setLaunchMode(desc, wizard.getLaunchMode());
|
||||||
|
}
|
||||||
|
wizard.getWorkingCopy().doSave();// that would trigger active config change
|
||||||
return Status.OK_STATUS;
|
return Status.OK_STATUS;
|
||||||
} catch (CoreException e) {
|
} catch (CoreException e) {
|
||||||
return e.getStatus();
|
return e.getStatus();
|
||||||
|
|
Loading…
Add table
Reference in a new issue