From 96cf52e320c4745e2e534dc519176daf9e5d364e Mon Sep 17 00:00:00 2001 From: Robert Sesek Date: Wed, 11 Jun 2008 09:46:12 -0400 Subject: [PATCH] Have the BreakpointManager tell the DebuggerConnection about breakpoints, rather than controllers * Source/BreakpointManager.m: (addBreakpoint:) (removeBreakpointAt:inFile:) * Source/DebuggerWindowController.m: (gutterClickedAtLine:forFile:) --- Source/BreakpointManager.m | 2 ++ Source/DebuggerWindowController.m | 3 +-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Source/BreakpointManager.m b/Source/BreakpointManager.m index 545235a..0b2e431 100644 --- a/Source/BreakpointManager.m +++ b/Source/BreakpointManager.m @@ -56,6 +56,7 @@ if (![breakpoints containsObject:bp]) { [breakpoints addObject:bp]; + [connection addBreakpoint:bp]; } } @@ -69,6 +70,7 @@ if ([b line] == line && [[b file] isEqualToString:file]) { [breakpoints removeObject:b]; + [connection removeBreakpoint:b]; return b; } } diff --git a/Source/DebuggerWindowController.m b/Source/DebuggerWindowController.m index 1822046..fda30ac 100644 --- a/Source/DebuggerWindowController.m +++ b/Source/DebuggerWindowController.m @@ -289,13 +289,12 @@ if ([mngr hasBreakpointAt:line inFile:file]) { - [connection removeBreakpoint:[mngr removeBreakpointAt:line inFile:file]]; + [mngr removeBreakpointAt:line inFile:file]; } else { Breakpoint *bp = [[Breakpoint alloc] initWithLine:line inFile:file]; [mngr addBreakpoint:bp]; - [connection addBreakpoint:bp]; } [[sourceViewer numberView] setMarkers:[mngr breakpointsForFile:file]]; -- 2.43.5