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

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

Issue 10534093: TabContentsWrapper -> TabContents, part 37. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 (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 #pragma once 7 #pragma once
8 8
9 #import <Cocoa/Cocoa.h> 9 #import <Cocoa/Cocoa.h>
10 10
11 #include "base/memory/scoped_nsobject.h" 11 #include "base/memory/scoped_nsobject.h"
12 #include "base/memory/scoped_ptr.h" 12 #include "base/memory/scoped_ptr.h"
13 #import "chrome/browser/ui/cocoa/tabs/tab_controller_target.h" 13 #import "chrome/browser/ui/cocoa/tabs/tab_controller_target.h"
14 #import "chrome/browser/ui/cocoa/url_drop_target.h" 14 #import "chrome/browser/ui/cocoa/url_drop_target.h"
15 #include "chrome/browser/ui/tabs/hover_tab_selector.h" 15 #include "chrome/browser/ui/tabs/hover_tab_selector.h"
16 #import "third_party/GTM/AppKit/GTMWindowSheetController.h" 16 #import "third_party/GTM/AppKit/GTMWindowSheetController.h"
17 17
18 @class CrTrackingArea; 18 @class CrTrackingArea;
19 @class NewTabButton; 19 @class NewTabButton;
20 @class TabContentsController; 20 @class TabContentsController;
21 @class TabView; 21 @class TabView;
22 @class TabStripDragController; 22 @class TabStripDragController;
23 @class TabStripView; 23 @class TabStripView;
24 24
25 class Browser; 25 class Browser;
26 class ConstrainedWindowMac; 26 class ConstrainedWindowMac;
27 class TabContents; 27 class TabContents;
28 typedef TabContents TabContentsWrapper;
29 class TabStripModelObserverBridge; 28 class TabStripModelObserverBridge;
30 class TabStripModel; 29 class TabStripModel;
31 30
32 // The interface for the tab strip controller's delegate. 31 // The interface for the tab strip controller's delegate.
33 // Delegating TabStripModelObserverBridge's events (in lieu of directly 32 // Delegating TabStripModelObserverBridge's events (in lieu of directly
34 // subscribing to TabStripModelObserverBridge events, as TabStripController 33 // subscribing to TabStripModelObserverBridge events, as TabStripController
35 // does) is necessary to guarantee a proper order of subviews layout updates, 34 // does) is necessary to guarantee a proper order of subviews layout updates,
36 // otherwise it might trigger unnesessary content relayout, UI flickering etc. 35 // otherwise it might trigger unnesessary content relayout, UI flickering etc.
37 @protocol TabStripControllerDelegate 36 @protocol TabStripControllerDelegate
38 37
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 // Return the view for the currently active tab. 168 // Return the view for the currently active tab.
170 - (NSView*)activeTabView; 169 - (NSView*)activeTabView;
171 170
172 // Set the frame of the active tab, also updates the internal frame dict. 171 // Set the frame of the active tab, also updates the internal frame dict.
173 - (void)setFrameOfActiveTab:(NSRect)frame; 172 - (void)setFrameOfActiveTab:(NSRect)frame;
174 173
175 // Move the given tab at index |from| in this window to the location of the 174 // Move the given tab at index |from| in this window to the location of the
176 // current placeholder. 175 // current placeholder.
177 - (void)moveTabFromIndex:(NSInteger)from; 176 - (void)moveTabFromIndex:(NSInteger)from;
178 177
179 // Drop a given TabContentsWrapper at the location of the current placeholder. 178 // Drop a given TabContents at the location of the current placeholder.
180 // If there is no placeholder, it will go at the end. Used when dragging from 179 // If there is no placeholder, it will go at the end. Used when dragging from
181 // another window when we don't have access to the WebContents as part of our 180 // another window when we don't have access to the WebContents as part of our
182 // strip. |frame| is in the coordinate system of the tab strip view and 181 // strip. |frame| is in the coordinate system of the tab strip view and
183 // represents where the user dropped the new tab so it can be animated into its 182 // represents where the user dropped the new tab so it can be animated into its
184 // correct location when the tab is added to the model. If the tab was pinned in 183 // correct location when the tab is added to the model. If the tab was pinned in
185 // its previous window, setting |pinned| to YES will propagate that state to the 184 // its previous window, setting |pinned| to YES will propagate that state to the
186 // new window. Mini-tabs are either app or pinned tabs; the app state is stored 185 // new window. Mini-tabs are either app or pinned tabs; the app state is stored
187 // by the |contents|, but the |pinned| state is the caller's responsibility. 186 // by the |contents|, but the |pinned| state is the caller's responsibility.
188 - (void)dropTabContents:(TabContentsWrapper*)contents 187 - (void)dropTabContents:(TabContents*)contents
189 withFrame:(NSRect)frame 188 withFrame:(NSRect)frame
190 asPinnedTab:(BOOL)pinned; 189 asPinnedTab:(BOOL)pinned;
191 190
192 // Returns the index of the subview |view|. Returns -1 if not present. Takes 191 // Returns the index of the subview |view|. Returns -1 if not present. Takes
193 // closing tabs into account such that this index will correctly match the tab 192 // closing tabs into account such that this index will correctly match the tab
194 // model. If |view| is in the process of closing, returns -1, as closing tabs 193 // model. If |view| is in the process of closing, returns -1, as closing tabs
195 // are no longer in the model. 194 // are no longer in the model.
196 - (NSInteger)modelIndexForTabView:(NSView*)view; 195 - (NSInteger)modelIndexForTabView:(NSView*)view;
197 196
198 // Return the view at a given index. 197 // Return the view at a given index.
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
256 - (TabContentsController*)activeTabContentsController; 255 - (TabContentsController*)activeTabContentsController;
257 256
258 // See comments in browser_window_controller.h for documentation about these 257 // See comments in browser_window_controller.h for documentation about these
259 // functions. 258 // functions.
260 - (void)attachConstrainedWindow:(ConstrainedWindowMac*)window; 259 - (void)attachConstrainedWindow:(ConstrainedWindowMac*)window;
261 - (void)removeConstrainedWindow:(ConstrainedWindowMac*)window; 260 - (void)removeConstrainedWindow:(ConstrainedWindowMac*)window;
262 261
263 @end 262 @end
264 263
265 #endif // CHROME_BROWSER_UI_COCOA_TABS_TAB_STRIP_CONTROLLER_H_ 264 #endif // CHROME_BROWSER_UI_COCOA_TABS_TAB_STRIP_CONTROLLER_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/tabpose_window_unittest.mm ('k') | chrome/browser/ui/cocoa/tabs/tab_strip_controller.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698