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

Side by Side Diff: chrome/browser/ui/cocoa/bookmarks/bookmark_bar_controller.h

Issue 2567973002: Mac: Fix lifetime problem under BookmarkBarController stopPulsingBookmarkNode. (Closed)
Patch Set: Guarantee a crash Created 4 years 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
« no previous file with comments | « no previous file | chrome/browser/ui/cocoa/bookmarks/bookmark_bar_controller.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 #ifndef CHROME_BROWSER_UI_COCOA_BOOKMARKS_BOOKMARK_BAR_CONTROLLER_H_ 5 #ifndef CHROME_BROWSER_UI_COCOA_BOOKMARKS_BOOKMARK_BAR_CONTROLLER_H_
6 #define CHROME_BROWSER_UI_COCOA_BOOKMARKS_BOOKMARK_BAR_CONTROLLER_H_ 6 #define CHROME_BROWSER_UI_COCOA_BOOKMARKS_BOOKMARK_BAR_CONTROLLER_H_
7 7
8 #import <Cocoa/Cocoa.h> 8 #import <Cocoa/Cocoa.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after
287 BOOL hasInsertionPos_; 287 BOOL hasInsertionPos_;
288 288
289 // The x point on the bar where the left edge of the new item will end 289 // The x point on the bar where the left edge of the new item will end
290 // up if it is dropped. 290 // up if it is dropped.
291 CGFloat insertionPos_; 291 CGFloat insertionPos_;
292 292
293 // Controller responsible for all bookmark context menus. 293 // Controller responsible for all bookmark context menus.
294 base::scoped_nsobject<BookmarkContextMenuCocoaController> 294 base::scoped_nsobject<BookmarkContextMenuCocoaController>
295 contextMenuController_; 295 contextMenuController_;
296 296
297 // Weak pointer to the pulsed button for the currently pulsing node. We need 297 // The pulsed button for the currently pulsing node. We need to store this as
298 // to store this as it may not be possible to determine the pulsing button if 298 // it may not be possible to determine the pulsing button if the pulsing node
299 // the pulsing node is deleted. Nil if there is no pulsing node. 299 // is deleted. Nil if there is no pulsing node.
300 BookmarkButton* pulsingButton_; 300 base::scoped_nsobject<BookmarkButton> pulsingButton_;
301 301
302 // Specifically watch the currently pulsing node. This lets us stop pulsing 302 // Specifically watch the currently pulsing node. This lets us stop pulsing
303 // when anything happens to the node. Null if there is no pulsing node. 303 // when anything happens to the node. Null if there is no pulsing node.
304 std::unique_ptr<BookmarkModelObserverForCocoa> pulsingBookmarkObserver_; 304 std::unique_ptr<BookmarkModelObserverForCocoa> pulsingBookmarkObserver_;
305 } 305 }
306 306
307 @property(readonly, nonatomic) BookmarkBar::State currentState; 307 @property(readonly, nonatomic) BookmarkBar::State currentState;
308 @property(readonly, nonatomic) BookmarkBar::State lastState; 308 @property(readonly, nonatomic) BookmarkBar::State lastState;
309 @property(readonly, nonatomic) BOOL isAnimationRunning; 309 @property(readonly, nonatomic) BOOL isAnimationRunning;
310 @property(assign, nonatomic) id<BookmarkBarControllerDelegate> delegate; 310 @property(assign, nonatomic) id<BookmarkBarControllerDelegate> delegate;
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
458 - (BookmarkButton*)buttonForDroppingOnAtPoint:(NSPoint)point; 458 - (BookmarkButton*)buttonForDroppingOnAtPoint:(NSPoint)point;
459 - (BOOL)isEventAnExitEvent:(NSEvent*)event; 459 - (BOOL)isEventAnExitEvent:(NSEvent*)event;
460 - (BOOL)shrinkOrHideView:(NSView*)view forMaxX:(CGFloat)maxViewX; 460 - (BOOL)shrinkOrHideView:(NSView*)view forMaxX:(CGFloat)maxViewX;
461 - (void)unhighlightBookmark:(const bookmarks::BookmarkNode*)node; 461 - (void)unhighlightBookmark:(const bookmarks::BookmarkNode*)node;
462 462
463 // The following are for testing purposes only and are not used internally. 463 // The following are for testing purposes only and are not used internally.
464 - (NSMenu *)menuForFolderNode:(const bookmarks::BookmarkNode*)node; 464 - (NSMenu *)menuForFolderNode:(const bookmarks::BookmarkNode*)node;
465 @end 465 @end
466 466
467 #endif // CHROME_BROWSER_UI_COCOA_BOOKMARKS_BOOKMARK_BAR_CONTROLLER_H_ 467 #endif // CHROME_BROWSER_UI_COCOA_BOOKMARKS_BOOKMARK_BAR_CONTROLLER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/cocoa/bookmarks/bookmark_bar_controller.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698