Browse Source

Fixed SD2-1325: SharpDevelop brought in front of running console app

git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/branches/2.1@2635 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61
shortcuts
Daniel Grunwald 18 years ago
parent
commit
f86decdab1
  1. 11
      src/Main/Base/Project/Src/Services/Debugger/DebuggerService.cs

11
src/Main/Base/Project/Src/Services/Debugger/DebuggerService.cs

@ -101,14 +101,21 @@ namespace ICSharpCode.SharpDevelop.Debugging
public static event EventHandler DebugStopped; public static event EventHandler DebugStopped;
static void OnDebugStarted(object sender, EventArgs e) static void OnDebugStarted(object sender, EventArgs e)
{
// OnDebugStarted runs on the main thread, but for some reason we
// have to delay the layout change a bit to work around SD2-1325
WorkbenchSingleton.SafeThreadAsyncCall(OnDebugStartedInvoked);
if (DebugStarted != null)
DebugStarted(null, EventArgs.Empty);
}
static void OnDebugStartedInvoked()
{ {
WorkbenchSingleton.Workbench.WorkbenchLayout.StoreConfiguration(); WorkbenchSingleton.Workbench.WorkbenchLayout.StoreConfiguration();
oldLayoutConfiguration = LayoutConfiguration.CurrentLayoutName; oldLayoutConfiguration = LayoutConfiguration.CurrentLayoutName;
LayoutConfiguration.CurrentLayoutName = "Debug"; LayoutConfiguration.CurrentLayoutName = "Debug";
ClearDebugMessages(); ClearDebugMessages();
if (DebugStarted != null)
DebugStarted(null, e);
} }
static void OnDebugStopped(object sender, EventArgs e) static void OnDebugStopped(object sender, EventArgs e)

Loading…
Cancel
Save