File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -62,28 +62,24 @@ + (DebuggerController *)singleton
6262 return singleton ? singleton : [[self alloc ] init ];
6363}
6464
65- - (void )habdleCloseNotification : ( NSNotificationCenter *) nc
65+ - (void )habdleCloseNotification
6666{
67- [nc addObserver: self
67+ [[ NSNotificationCenter defaultCenter ] addObserver: self
6868 selector: @selector (handleWillClose: )
6969 name: @" NSWindowWillCloseNotification"
7070 object: [self window ]];
7171}
7272
7373- (id )init
7474{
75- NSNotificationCenter *nc;
76-
7775 if ( singleton ) {
7876 [self dealloc ];
7977 } else {
8078 [super init ];
8179 self = [super initWithWindowNibName: @" Debugger" ];
8280 singleton = self;
8381
84- nc = [NSNotificationCenter defaultCenter ];
85-
86- [self performSelectorOnMainThread: @selector (habdleCloseNotification ) withObject: nc waitUntilDone: YES ];
82+ [self performSelectorOnMainThread: @selector (habdleCloseNotification ) withObject: nil waitUntilDone: YES ];
8783 [self setWindowFrameAutosaveName: @" DebuggerWindow" ];
8884 }
8985
You can’t perform that action at this time.
0 commit comments