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

Side by Side Diff: chrome/browser/tabs/tab_strip_model_delegate.h

Issue 8800010: Update CreateTabContents to use a content::Referrer instead of a plain URL (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 9 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_TABS_TAB_STRIP_MODEL_DELEGATE_H_ 5 #ifndef CHROME_BROWSER_TABS_TAB_STRIP_MODEL_DELEGATE_H_
6 #define CHROME_BROWSER_TABS_TAB_STRIP_MODEL_DELEGATE_H_ 6 #define CHROME_BROWSER_TABS_TAB_STRIP_MODEL_DELEGATE_H_
7 #pragma once 7 #pragma once
8 8
9 #include "content/public/common/page_transition_types.h" 9 #include "content/public/common/page_transition_types.h"
10 10
11 class Browser; 11 class Browser;
12 class DockInfo; 12 class DockInfo;
13 class GURL; 13 class GURL;
14 class Profile; 14 class Profile;
15 class SiteInstance; 15 class SiteInstance;
16 class TabContents; 16 class TabContents;
17 class TabContentsWrapper; 17 class TabContentsWrapper;
18 namespace content {
19 struct Referrer;
20 }
18 namespace gfx { 21 namespace gfx {
19 class Rect; 22 class Rect;
20 } 23 }
21 24
22 /////////////////////////////////////////////////////////////////////////////// 25 ///////////////////////////////////////////////////////////////////////////////
23 // 26 //
24 // TabStripModelDelegate 27 // TabStripModelDelegate
25 // 28 //
26 // A delegate interface that the TabStripModel uses to perform work that it 29 // A delegate interface that the TabStripModel uses to perform work that it
27 // can't do itself, such as obtain a container HWND for creating new 30 // can't do itself, such as obtain a container HWND for creating new
(...skipping 28 matching lines...) Expand all
56 // Determines what drag actions are possible for the specified strip. 59 // Determines what drag actions are possible for the specified strip.
57 virtual int GetDragActions() const = 0; 60 virtual int GetDragActions() const = 0;
58 61
59 // Creates an appropriate TabContents for the given URL. This is handled by 62 // Creates an appropriate TabContents for the given URL. This is handled by
60 // the delegate since the TabContents may require special circumstances to 63 // the delegate since the TabContents may require special circumstances to
61 // exist for it to be constructed (e.g. a parent HWND). 64 // exist for it to be constructed (e.g. a parent HWND).
62 // If |defer_load| is true, the navigation controller doesn't load the url. 65 // If |defer_load| is true, the navigation controller doesn't load the url.
63 // If |instance| is not null, its process is used to render the tab. 66 // If |instance| is not null, its process is used to render the tab.
64 virtual TabContentsWrapper* CreateTabContentsForURL( 67 virtual TabContentsWrapper* CreateTabContentsForURL(
65 const GURL& url, 68 const GURL& url,
66 const GURL& referrer, 69 const content::Referrer& referrer,
67 Profile* profile, 70 Profile* profile,
68 content::PageTransition transition, 71 content::PageTransition transition,
69 bool defer_load, 72 bool defer_load,
70 SiteInstance* instance) const = 0; 73 SiteInstance* instance) const = 0;
71 74
72 // Returns whether some contents can be duplicated. 75 // Returns whether some contents can be duplicated.
73 virtual bool CanDuplicateContentsAt(int index) = 0; 76 virtual bool CanDuplicateContentsAt(int index) = 0;
74 77
75 // Duplicates the contents at the provided index and places it into its own 78 // Duplicates the contents at the provided index and places it into its own
76 // window. 79 // window.
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 virtual bool CanCloseTab() const = 0; 116 virtual bool CanCloseTab() const = 0;
114 117
115 // Returns true if the tab strip can use large icons. 118 // Returns true if the tab strip can use large icons.
116 virtual bool LargeIconsPermitted() const = 0; 119 virtual bool LargeIconsPermitted() const = 0;
117 120
118 protected: 121 protected:
119 virtual ~TabStripModelDelegate() {} 122 virtual ~TabStripModelDelegate() {}
120 }; 123 };
121 124
122 #endif // CHROME_BROWSER_TABS_TAB_STRIP_MODEL_DELEGATE_H_ 125 #endif // CHROME_BROWSER_TABS_TAB_STRIP_MODEL_DELEGATE_H_
OLDNEW
« no previous file with comments | « chrome/browser/tabs/default_tab_handler.cc ('k') | chrome/browser/tabs/tab_strip_model_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698