mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-10 18:45:26 +02:00
Make sure we apply when update buttons is called in new edit dialog.
Change-Id: I8a31af7d0700ac285ecaa30d2a884b45d439f46f
This commit is contained in:
parent
d16fcb8d49
commit
0aa31108c4
1 changed files with 14 additions and 1 deletions
|
@ -36,6 +36,7 @@ public class LaunchBarLaunchConfigDialog extends TitleAreaDialog implements ILau
|
||||||
private ILaunchConfigurationTabGroup group;
|
private ILaunchConfigurationTabGroup group;
|
||||||
private CTabFolder tabFolder;
|
private CTabFolder tabFolder;
|
||||||
private CTabItem lastSelection;
|
private CTabItem lastSelection;
|
||||||
|
private boolean initing;
|
||||||
|
|
||||||
public LaunchBarLaunchConfigDialog(Shell shell, ILaunchConfigurationWorkingCopy workingCopy,
|
public LaunchBarLaunchConfigDialog(Shell shell, ILaunchConfigurationWorkingCopy workingCopy,
|
||||||
ILaunchDescriptor descriptor, ILaunchMode mode, ILaunchTarget target) {
|
ILaunchDescriptor descriptor, ILaunchMode mode, ILaunchTarget target) {
|
||||||
|
@ -55,6 +56,8 @@ public class LaunchBarLaunchConfigDialog extends TitleAreaDialog implements ILau
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected Control createDialogArea(Composite parent) {
|
protected Control createDialogArea(Composite parent) {
|
||||||
|
initing = true;
|
||||||
|
|
||||||
// create the top level composite for the dialog area
|
// create the top level composite for the dialog area
|
||||||
Composite composite = new Composite(parent, SWT.NONE);
|
Composite composite = new Composite(parent, SWT.NONE);
|
||||||
GridLayout layout = new GridLayout();
|
GridLayout layout = new GridLayout();
|
||||||
|
@ -132,6 +135,7 @@ public class LaunchBarLaunchConfigDialog extends TitleAreaDialog implements ILau
|
||||||
Activator.log(e.getStatus());
|
Activator.log(e.getStatus());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
initing = false;
|
||||||
return composite;
|
return composite;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -150,7 +154,16 @@ public class LaunchBarLaunchConfigDialog extends TitleAreaDialog implements ILau
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void updateButtons() {
|
public void updateButtons() {
|
||||||
// TODO
|
// Lots of tabs want to be applied when this is called
|
||||||
|
if (!initing) {
|
||||||
|
ILaunchConfigurationTab[] tabs = getTabs();
|
||||||
|
if (tabFolder != null && tabs != null) {
|
||||||
|
int pageIndex = tabFolder.getSelectionIndex();
|
||||||
|
if (pageIndex >= 0) {
|
||||||
|
tabs[pageIndex].performApply(workingCopy);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
Loading…
Add table
Reference in a new issue