Permalink
Browse files

Add missing braces and add memdebug macros.

  • Loading branch information...
1 parent 5a2114a commit 977540fb0532f3a8c61b0e0ffe366b4e281094d1 @martinh martinh committed Mar 17, 2012
Showing with 7 additions and 5 deletions.
  1. +1 −1 app/PSMTabBarControl.m
  2. +1 −0 app/ViTabController.m
  3. +5 −4 app/ViWindowController.m
View
2 app/PSMTabBarControl.m
@@ -402,7 +402,7 @@ - (void)addTabViewItem:(NSTabViewItem *)item
- (void)removeTabForCell:(PSMTabBarCell *)cell
{
- MEMDEBUG(@"remove cell %@", cell);
+ DEBUG(@"remove cell %@", cell);
// unbind
[[cell indicator] unbind:@"animate"];
View
1 app/ViTabController.m
@@ -31,6 +31,7 @@ - (id)initWithViewController:(ViViewController *)initialViewController
[self addView:initialViewController];
[self setSelectedView:initialViewController];
}
+ DEBUG_INIT();
return self;
}
View
9 app/ViWindowController.m
@@ -78,9 +78,8 @@ - (id)init
[_jumpList setDelegate:self];
_parser = [[ViParser alloc] initWithDefaultMap:[ViMap normalMap]];
[self setBaseURL:[NSURL fileURLWithPath:NSHomeDirectory()]];
- MEMDEBUG(@"init %@", self);
}
-
+ DEBUG_INIT();
return self;
}
@@ -1182,15 +1181,17 @@ - (void)didCloseDocument:(ViDocument *)document andWindow:(BOOL)canCloseWindow
NSMutableSet *set = [NSMutableSet set];
for (docView in [document views]) {
DEBUG(@"docview %@ in window %@", docView, [[docView tabController] window]);
- if ([[docView tabController] window] == [self window])
+ if ([[docView tabController] window] == [self window]) {
[set addObject:docView];
+ }
}
DEBUG(@"closing remaining views in window %@: %@", [self window], set);
- for (docView in set)
+ for (docView in set) {
[self closeDocumentView:docView
canCloseDocument:YES /* The document is already being closed. */
canCloseWindow:canCloseWindow];
+ }
}
- (void)documentController:(NSDocumentController *)docController

0 comments on commit 977540f

Please sign in to comment.