Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(56)

Side by Side Diff: chrome/browser/ui/cocoa/bookmarks/bookmark_bubble_controller.mm

Issue 6046009: Move base/mac_util.h to base/mac and use the base::mac namespace.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #import "chrome/browser/ui/cocoa/bookmarks/bookmark_bubble_controller.h" 5 #import "chrome/browser/ui/cocoa/bookmarks/bookmark_bubble_controller.h"
6 6
7 #include "app/l10n_util_mac.h" 7 #include "app/l10n_util_mac.h"
8 #include "base/mac_util.h" 8 #include "base/mac/mac_util.h"
9 #include "base/sys_string_conversions.h" 9 #include "base/sys_string_conversions.h"
10 #include "base/utf_string_conversions.h" // TODO(viettrungluu): remove 10 #include "base/utf_string_conversions.h" // TODO(viettrungluu): remove
11 #include "chrome/browser/bookmarks/bookmark_model.h" 11 #include "chrome/browser/bookmarks/bookmark_model.h"
12 #include "chrome/browser/metrics/user_metrics.h" 12 #include "chrome/browser/metrics/user_metrics.h"
13 #import "chrome/browser/ui/cocoa/bookmarks/bookmark_button.h" 13 #import "chrome/browser/ui/cocoa/bookmarks/bookmark_button.h"
14 #import "chrome/browser/ui/cocoa/browser_window_controller.h" 14 #import "chrome/browser/ui/cocoa/browser_window_controller.h"
15 #import "chrome/browser/ui/cocoa/info_bubble_view.h" 15 #import "chrome/browser/ui/cocoa/info_bubble_view.h"
16 #include "chrome/common/notification_observer.h" 16 #include "chrome/common/notification_observer.h"
17 #include "chrome/common/notification_registrar.h" 17 #include "chrome/common/notification_registrar.h"
18 #include "chrome/common/notification_service.h" 18 #include "chrome/common/notification_service.h"
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 object = [[ChooseAnotherFolder alloc] init]; 81 object = [[ChooseAnotherFolder alloc] init];
82 } 82 }
83 return object; 83 return object;
84 } 84 }
85 85
86 - (id)initWithParentWindow:(NSWindow*)parentWindow 86 - (id)initWithParentWindow:(NSWindow*)parentWindow
87 model:(BookmarkModel*)model 87 model:(BookmarkModel*)model
88 node:(const BookmarkNode*)node 88 node:(const BookmarkNode*)node
89 alreadyBookmarked:(BOOL)alreadyBookmarked { 89 alreadyBookmarked:(BOOL)alreadyBookmarked {
90 NSString* nibPath = 90 NSString* nibPath =
91 [mac_util::MainAppBundle() pathForResource:@"BookmarkBubble" 91 [base::mac::MainAppBundle() pathForResource:@"BookmarkBubble"
92 ofType:@"nib"]; 92 ofType:@"nib"];
93 if ((self = [super initWithWindowNibPath:nibPath owner:self])) { 93 if ((self = [super initWithWindowNibPath:nibPath owner:self])) {
94 parentWindow_ = parentWindow; 94 parentWindow_ = parentWindow;
95 model_ = model; 95 model_ = model;
96 node_ = node; 96 node_ = node;
97 alreadyBookmarked_ = alreadyBookmarked; 97 alreadyBookmarked_ = alreadyBookmarked;
98 98
99 // Watch to see if the parent window closes, and if so, close this one. 99 // Watch to see if the parent window closes, and if so, close this one.
100 NSNotificationCenter* center = [NSNotificationCenter defaultCenter]; 100 NSNotificationCenter* center = [NSNotificationCenter defaultCenter];
101 [center addObserver:self 101 [center addObserver:self
(...skipping 317 matching lines...) Expand 10 before | Expand all | Expand 10 after
419 NSInteger idx = [menu indexOfItemWithRepresentedObject:parentValue]; 419 NSInteger idx = [menu indexOfItemWithRepresentedObject:parentValue];
420 DCHECK(idx != -1); 420 DCHECK(idx != -1);
421 [folderPopUpButton_ selectItemAtIndex:idx]; 421 [folderPopUpButton_ selectItemAtIndex:idx];
422 } 422 }
423 423
424 - (NSPopUpButton*)folderPopUpButton { 424 - (NSPopUpButton*)folderPopUpButton {
425 return folderPopUpButton_; 425 return folderPopUpButton_;
426 } 426 }
427 427
428 @end // implementation BookmarkBubbleController(ExposedForUnitTesting) 428 @end // implementation BookmarkBubbleController(ExposedForUnitTesting)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698