Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimeon Andreev2018-09-07 07:20:44 -0400
committerJonah Graham2018-09-07 16:34:13 -0400
commit8a73297c10974eb3f502997501f5a2630c973438 (patch)
treea128ba378e065929aa2a758e6d5abfaa5b018edc /dsf-gdb
parent6870f55fbb436f47f3b7353baf53f77f9f5c2f54 (diff)
downloadorg.eclipse.cdt-8a73297c10974eb3f502997501f5a2630c973438.tar.gz
org.eclipse.cdt-8a73297c10974eb3f502997501f5a2630c973438.tar.xz
org.eclipse.cdt-8a73297c10974eb3f502997501f5a2630c973438.zip
Bug 538785 - Select Processes dialog should remember when resized
With this change, the Select Processes dialog will remember its new size if it was resized by the user. Change-Id: I27161ae5b5332db87cc9876aa23cf8fd8c751a80 Signed-off-by: Simeon Andreev <simeon.danailov.andreev@gmail.com>
Diffstat (limited to 'dsf-gdb')
-rw-r--r--dsf-gdb/org.eclipse.cdt.dsf.gdb.ui/src/org/eclipse/cdt/dsf/gdb/internal/ui/launching/ProcessPrompterDialog.java16
1 files changed, 16 insertions, 0 deletions
diff --git a/dsf-gdb/org.eclipse.cdt.dsf.gdb.ui/src/org/eclipse/cdt/dsf/gdb/internal/ui/launching/ProcessPrompterDialog.java b/dsf-gdb/org.eclipse.cdt.dsf.gdb.ui/src/org/eclipse/cdt/dsf/gdb/internal/ui/launching/ProcessPrompterDialog.java
index 433b4e4fdd..517ac691ef 100644
--- a/dsf-gdb/org.eclipse.cdt.dsf.gdb.ui/src/org/eclipse/cdt/dsf/gdb/internal/ui/launching/ProcessPrompterDialog.java
+++ b/dsf-gdb/org.eclipse.cdt.dsf.gdb.ui/src/org/eclipse/cdt/dsf/gdb/internal/ui/launching/ProcessPrompterDialog.java
@@ -13,9 +13,12 @@ package org.eclipse.cdt.dsf.gdb.internal.ui.launching;
import java.util.Arrays;
+import org.eclipse.cdt.dsf.gdb.internal.ui.GdbUIPlugin;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Status;
+import org.eclipse.jface.dialogs.Dialog;
import org.eclipse.jface.dialogs.IDialogConstants;
+import org.eclipse.jface.dialogs.IDialogSettings;
import org.eclipse.jface.viewers.ILabelProvider;
import org.eclipse.swt.SWT;
import org.eclipse.swt.widgets.Composite;
@@ -36,9 +39,12 @@ import org.eclipse.ui.dialogs.TwoPaneElementSelector;
*/
public class ProcessPrompterDialog extends TwoPaneElementSelector {
+ private static final String DIALOG_SETTINGS_SECTION_ID = "processPrompterDialog"; //$NON-NLS-1$
+
public ProcessPrompterDialog(Shell parent, ILabelProvider elementRenderer,
ILabelProvider qualifierRenderer) {
super(parent, elementRenderer, qualifierRenderer);
+ setDialogBoundsSettings(getDialogBoundsSettings(), Dialog.DIALOG_PERSISTSIZE);
}
/*
@@ -118,4 +124,14 @@ public class ProcessPrompterDialog extends TwoPaneElementSelector {
return super.validateCurrentSelection();
}
+
+ @Override
+ protected IDialogSettings getDialogBoundsSettings() {
+ IDialogSettings settings = GdbUIPlugin.getDefault().getDialogSettings();
+ IDialogSettings section = settings.getSection(DIALOG_SETTINGS_SECTION_ID);
+ if (section == null) {
+ section = settings.addNewSection(DIALOG_SETTINGS_SECTION_ID);
+ }
+ return section;
+ }
}

Back to the top