From 3d3265e0b80fbea230793d5dddc864b4215d55cd Mon Sep 17 00:00:00 2001 From: Robert Sesek Date: Thu, 16 Dec 2010 09:18:41 -0500 Subject: [PATCH] * Store the DebuggerAttached value in the preferences * Respect the attached checkbox on start --- English.lproj/Debugger.xib | 54 +++++++++++++++++++++++++++++++++---- Source/AppDelegate.m | 1 + Source/DebuggerController.h | 4 ++- Source/DebuggerController.m | 1 + 4 files changed, 54 insertions(+), 6 deletions(-) diff --git a/English.lproj/Debugger.xib b/English.lproj/Debugger.xib index 6ef7069..92b0e47 100644 --- a/English.lproj/Debugger.xib +++ b/English.lproj/Debugger.xib @@ -12,7 +12,7 @@ YES - + YES @@ -1197,6 +1197,7 @@ {402, 402} + @@ -1229,6 +1230,7 @@ {{-1, -1}, {402, 402}} + 560 @@ -1242,6 +1244,10 @@ InspectorWindow + + YES + DebuggerAttached + YES @@ -1612,6 +1618,30 @@ 594 + + + attachedCheckbox_ + + + + 595 + + + + value: values.DebuggerAttached + + + + + + value: values.DebuggerAttached + value + values.DebuggerAttached + 2 + + + 596 + @@ -2204,7 +2234,7 @@ com.apple.InterfaceBuilder.CocoaPlugin - {{449, 334}, {617, 227}} + {{444, 325}, {617, 227}} com.apple.InterfaceBuilder.CocoaPlugin {{418, 770}, {617, 0}} com.apple.InterfaceBuilder.CocoaPlugin @@ -2233,11 +2263,11 @@ com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin - {{373, 60}, {769, 501}} + {{368, 51}, {769, 501}} com.apple.InterfaceBuilder.CocoaPlugin - {{373, 60}, {769, 501}} + {{368, 51}, {769, 501}} {{344, 269}, {769, 501}} @@ -2267,7 +2297,7 @@ - 594 + 596 @@ -2315,6 +2345,7 @@ YES attachedToggled: + run: showInspectorWindow: stepIn: stepOut: @@ -2327,6 +2358,7 @@ id id id + id @@ -2334,6 +2366,7 @@ YES attachedToggled: + run: showInspectorWindow: stepIn: stepOut: @@ -2345,6 +2378,10 @@ attachedToggled: id + + run: + id + showInspectorWindow: id @@ -2367,6 +2404,7 @@ YES YES + attachedCheckbox_ errormsg inspector sourceViewer @@ -2377,6 +2415,7 @@ YES + NSButton NSTextField NSWindow BSSourceView @@ -2390,6 +2429,7 @@ YES YES + attachedCheckbox_ errormsg inspector sourceViewer @@ -2400,6 +2440,10 @@ YES + + attachedCheckbox_ + NSButton + errormsg NSTextField diff --git a/Source/AppDelegate.m b/Source/AppDelegate.m index 75f4993..952ab3a 100644 --- a/Source/AppDelegate.m +++ b/Source/AppDelegate.m @@ -36,6 +36,7 @@ [NSNumber numberWithBool:YES], @"InspectorWindowVisible", [NSMutableArray array], @"PathReplacements", [NSNumber numberWithBool:YES], @"BreakOnFirstLine", + [NSNumber numberWithBool:YES], @"DebuggerAttached", nil ]; diff --git a/Source/DebuggerController.h b/Source/DebuggerController.h index cd464b4..080f403 100644 --- a/Source/DebuggerController.h +++ b/Source/DebuggerController.h @@ -31,7 +31,9 @@ // Dictionary of transcations to tree nodes that are used when properties // are requested from the backend. NSMutableDictionary* pendingProperties_; - + + IBOutlet NSButton* attachedCheckbox_; + StackController* stackController; IBOutlet NSArrayController* stackArrayController; diff --git a/Source/DebuggerController.m b/Source/DebuggerController.m index b74e3a0..c3d2dce 100644 --- a/Source/DebuggerController.m +++ b/Source/DebuggerController.m @@ -75,6 +75,7 @@ [[self window] setTitle:[NSString stringWithFormat:@"GDBp @ %@:%d", [connection remoteHost], [connection port]]]; [sourceViewer setDelegate:self]; [stackArrayController setSortDescriptors:[NSArray arrayWithObject:[[[NSSortDescriptor alloc] initWithKey:@"index" ascending:YES] autorelease]]]; + self.connection.attached = [attachedCheckbox_ state] == NSOnState; } /** -- 2.43.5