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

Side by Side Diff: chrome/browser/ui/cocoa/tabs/tab_strip_controller.h

Issue 1221173003: [Mac] Inform reference counted objects that hold a weak Browser* when the Browser is being destroye… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments. Created 5 years, 5 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
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_TABS_TAB_STRIP_CONTROLLER_H_ 5 #ifndef CHROME_BROWSER_UI_COCOA_TABS_TAB_STRIP_CONTROLLER_H_
6 #define CHROME_BROWSER_UI_COCOA_TABS_TAB_STRIP_CONTROLLER_H_ 6 #define CHROME_BROWSER_UI_COCOA_TABS_TAB_STRIP_CONTROLLER_H_
7 7
8 #import <Cocoa/Cocoa.h> 8 #import <Cocoa/Cocoa.h>
9 9
10 #include "base/mac/scoped_nsobject.h" 10 #include "base/mac/scoped_nsobject.h"
11 #include "base/memory/scoped_ptr.h" 11 #include "base/memory/scoped_ptr.h"
12 #import "chrome/browser/ui/cocoa/has_weak_browser_pointer.h"
12 #import "chrome/browser/ui/cocoa/tabs/tab_controller_target.h" 13 #import "chrome/browser/ui/cocoa/tabs/tab_controller_target.h"
13 #import "chrome/browser/ui/cocoa/url_drop_target.h" 14 #import "chrome/browser/ui/cocoa/url_drop_target.h"
14 #include "chrome/browser/ui/tabs/hover_tab_selector.h" 15 #include "chrome/browser/ui/tabs/hover_tab_selector.h"
15 16
16 @class CrTrackingArea; 17 @class CrTrackingArea;
17 @class NewTabButton; 18 @class NewTabButton;
18 @class TabContentsController; 19 @class TabContentsController;
19 @class TabView; 20 @class TabView;
20 @class TabStripDragController; 21 @class TabStripDragController;
21 @class TabStripView; 22 @class TabStripView;
(...skipping 25 matching lines...) Expand all
47 48
48 @end 49 @end
49 50
50 // A class that handles managing the tab strip in a browser window. It uses 51 // A class that handles managing the tab strip in a browser window. It uses
51 // a supporting C++ bridge object to register for notifications from the 52 // a supporting C++ bridge object to register for notifications from the
52 // TabStripModel. The Obj-C part of this class handles drag and drop and all 53 // TabStripModel. The Obj-C part of this class handles drag and drop and all
53 // the other Cocoa-y aspects. 54 // the other Cocoa-y aspects.
54 // 55 //
55 // For a full description of the design, see 56 // For a full description of the design, see
56 // http://www.chromium.org/developers/design-documents/tab-strip-mac 57 // http://www.chromium.org/developers/design-documents/tab-strip-mac
57 @interface TabStripController : 58 @interface TabStripController : NSObject<TabControllerTarget,
58 NSObject<TabControllerTarget, 59 URLDropTargetController,
59 URLDropTargetController> { 60 HasWeakBrowserPointer> {
60 @private 61 @private
61 base::scoped_nsobject<TabStripView> tabStripView_; 62 base::scoped_nsobject<TabStripView> tabStripView_;
62 NSView* switchView_; // weak 63 NSView* switchView_; // weak
63 base::scoped_nsobject<NSView> dragBlockingView_; // avoid bad window server 64 base::scoped_nsobject<NSView> dragBlockingView_; // avoid bad window server
64 // drags 65 // drags
65 NewTabButton* newTabButton_; // weak, obtained from the nib. 66 NewTabButton* newTabButton_; // weak, obtained from the nib.
66 67
67 // The controller that manages all the interactions of dragging tabs. 68 // The controller that manages all the interactions of dragging tabs.
68 base::scoped_nsobject<TabStripDragController> dragController_; 69 base::scoped_nsobject<TabStripDragController> dragController_;
69 70
(...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after
265 - (void)removeCustomWindowControls; 266 - (void)removeCustomWindowControls;
266 267
267 @end 268 @end
268 269
269 @interface TabStripController(TestingAPI) 270 @interface TabStripController(TestingAPI)
270 - (void)setTabTitle:(TabController*)tab 271 - (void)setTabTitle:(TabController*)tab
271 withContents:(content::WebContents*)contents; 272 withContents:(content::WebContents*)contents;
272 @end 273 @end
273 274
274 #endif // CHROME_BROWSER_UI_COCOA_TABS_TAB_STRIP_CONTROLLER_H_ 275 #endif // CHROME_BROWSER_UI_COCOA_TABS_TAB_STRIP_CONTROLLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698