1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-24 17:35:35 +02:00

Bug 488874 - attach dialog sometimes does not appear, because no active

shell is found

Change-Id: I039c90677152efe1611049d11cd9b6102c99f86b
This commit is contained in:
Marc Dumais 2016-03-02 11:08:18 -05:00
parent 038783cf5f
commit a21b4f2331

View file

@ -71,7 +71,6 @@ import org.eclipse.debug.core.IRequest;
import org.eclipse.debug.core.commands.IDebugCommandRequest;
import org.eclipse.debug.core.commands.IEnabledStateRequest;
import org.eclipse.swt.SWT;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.FileDialog;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.ui.progress.UIJob;
@ -222,7 +221,8 @@ public class GdbConnectCommand extends RefreshableDebugCommand implements IConne
if (binaryPath == null) {
// prompt for the binary path
Shell shell = Display.getCurrent().getActiveShell();
Shell shell = GdbUIPlugin.getShell();
if (shell != null) {
FileDialog fd = new FileDialog(shell, SWT.NONE);
fd.setText(fTitle);