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

Side by Side Diff: chrome/browser/ui/cocoa/browser_window_controller.mm

Issue 312093007: Revert of Added BookmarkClient::CanBeEditedByUser. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 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/browser_window_controller.h" 5 #import "chrome/browser/ui/cocoa/browser_window_controller.h"
6 6
7 #include <cmath> 7 #include <cmath>
8 #include <numeric> 8 #include <numeric>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 1702 matching lines...) Expand 10 before | Expand all | Expand 10 after
1713 - (NSPoint)bookmarkBubblePoint { 1713 - (NSPoint)bookmarkBubblePoint {
1714 return [toolbarController_ bookmarkBubblePoint]; 1714 return [toolbarController_ bookmarkBubblePoint];
1715 } 1715 }
1716 1716
1717 // Show the bookmark bubble (e.g. user just clicked on the STAR). 1717 // Show the bookmark bubble (e.g. user just clicked on the STAR).
1718 - (void)showBookmarkBubbleForURL:(const GURL&)url 1718 - (void)showBookmarkBubbleForURL:(const GURL&)url
1719 alreadyBookmarked:(BOOL)alreadyMarked { 1719 alreadyBookmarked:(BOOL)alreadyMarked {
1720 if (!bookmarkBubbleController_) { 1720 if (!bookmarkBubbleController_) {
1721 BookmarkModel* model = 1721 BookmarkModel* model =
1722 BookmarkModelFactory::GetForProfile(browser_->profile()); 1722 BookmarkModelFactory::GetForProfile(browser_->profile());
1723 const BookmarkNode* node = model->GetMostRecentlyAddedUserNodeForURL(url); 1723 const BookmarkNode* node = model->GetMostRecentlyAddedNodeForURL(url);
1724 bookmarkBubbleController_ = 1724 bookmarkBubbleController_ =
1725 [[BookmarkBubbleController alloc] initWithParentWindow:[self window] 1725 [[BookmarkBubbleController alloc] initWithParentWindow:[self window]
1726 model:model 1726 model:model
1727 node:node 1727 node:node
1728 alreadyBookmarked:alreadyMarked]; 1728 alreadyBookmarked:alreadyMarked];
1729 [bookmarkBubbleController_ showWindow:self]; 1729 [bookmarkBubbleController_ showWindow:self];
1730 NSNotificationCenter* center = [NSNotificationCenter defaultCenter]; 1730 NSNotificationCenter* center = [NSNotificationCenter defaultCenter];
1731 [center addObserver:self 1731 [center addObserver:self
1732 selector:@selector(bookmarkBubbleWindowWillClose:) 1732 selector:@selector(bookmarkBubbleWindowWillClose:)
1733 name:NSWindowWillCloseNotification 1733 name:NSWindowWillCloseNotification
(...skipping 568 matching lines...) Expand 10 before | Expand all | Expand 10 after
2302 2302
2303 - (BOOL)supportsBookmarkBar { 2303 - (BOOL)supportsBookmarkBar {
2304 return [self supportsWindowFeature:Browser::FEATURE_BOOKMARKBAR]; 2304 return [self supportsWindowFeature:Browser::FEATURE_BOOKMARKBAR];
2305 } 2305 }
2306 2306
2307 - (BOOL)isTabbedWindow { 2307 - (BOOL)isTabbedWindow {
2308 return browser_->is_type_tabbed(); 2308 return browser_->is_type_tabbed();
2309 } 2309 }
2310 2310
2311 @end // @implementation BrowserWindowController(WindowType) 2311 @end // @implementation BrowserWindowController(WindowType)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698