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

Unified Diff: chrome/browser/cocoa/tab_strip_controller.h

Issue 526001: Mac: Make devtools window dockable. (Closed)
Patch Set: copyediting Created 10 years, 12 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/cocoa/tab_contents_controller.mm ('k') | chrome/browser/cocoa/tab_strip_controller.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/cocoa/tab_strip_controller.h
diff --git a/chrome/browser/cocoa/tab_strip_controller.h b/chrome/browser/cocoa/tab_strip_controller.h
index 838c00ae59aab83b502b1b3d6cbc3c47b918667a..f5f8d9d495b0ee1897df912f5f4c477606215436 100644
--- a/chrome/browser/cocoa/tab_strip_controller.h
+++ b/chrome/browser/cocoa/tab_strip_controller.h
@@ -16,6 +16,7 @@
#import "chrome/browser/cocoa/url_drop_target.h"
#import "third_party/GTM/AppKit/GTMWindowSheetController.h"
+@class TabContentsController;
@class TabView;
@class TabStripView;
@@ -36,7 +37,6 @@ class ToolbarModel;
// then handles replacing the contentView of the window. As tabs are switched,
// the single child of the contentView is swapped around to hold the contents
// (toolbar and all) representing that tab.
-
@interface TabStripController :
NSObject<TabControllerTarget,
URLDropTargetController,
@@ -53,13 +53,19 @@ class ToolbarModel;
scoped_ptr<TabStripModelObserverBridge> bridge_;
Browser* browser_; // weak
TabStripModel* tabStripModel_; // weak
+
// Access to the TabContentsControllers (which own the parent view
- // for the toolbar and associated tab contents) given an index. This needs
- // to be kept in the same order as the tab strip's model as we will be
- // using its index from the TabStripModelObserver calls.
+ // for the toolbar and associated tab contents) given an index. Call
+ // |indexFromModelIndex:| to convert a |tabStripModel_| index to a
+ // |tabContentsArray_| index. Do NOT assume that the indices of
+ // |tabStripModel_| and this array are identical, this is e.g. not true while
+ // tabs are animating closed (closed tabs are removed from |tabStripModel_|
+ // immediately, but from |tabContentsArray_| only after their close animation
+ // has completed).
scoped_nsobject<NSMutableArray> tabContentsArray_;
- // An array of TabControllers which manage the actual tab views. As above,
- // this is kept in the same order as the tab strip model.
+ // An array of TabControllers which manage the actual tab views. See note
+ // above |tabContentsArray_|. |tabContentsArray_| and |tabArray_| always
+ // contain objects belonging to the same tabs at the same indices.
scoped_nsobject<NSMutableArray> tabArray_;
// Set of TabControllers that are currently animating closed.
@@ -183,10 +189,14 @@ class ToolbarModel;
// for the per-tab sheets.
- (GTMWindowSheetController*)sheetController;
+// Returns the currently active TabContentsController.
+- (TabContentsController*)activeTabContentsController;
+
// See comments in browser_window_controller.h for documentation about these
// functions.
- (BOOL)attachConstrainedWindow:(ConstrainedWindowMac*)window;
- (void)removeConstrainedWindow:(ConstrainedWindowMac*)window;
+- (void)updateDevToolsForContents:(TabContents*)contents;
@end
« no previous file with comments | « chrome/browser/cocoa/tab_contents_controller.mm ('k') | chrome/browser/cocoa/tab_strip_controller.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698