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

Side by Side Diff: chrome/browser/ui/browser_tab_contents.cc

Issue 13375017: Move the ViewType enum to extensions\common. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 7 years, 8 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 #include "chrome/browser/ui/browser_tab_contents.h" 5 #include "chrome/browser/ui/browser_tab_contents.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "chrome/browser/content_settings/tab_specific_content_settings.h" 8 #include "chrome/browser/content_settings/tab_specific_content_settings.h"
9 #include "chrome/browser/extensions/api/web_navigation/web_navigation_api.h" 9 #include "chrome/browser/extensions/api/web_navigation/web_navigation_api.h"
10 #include "chrome/browser/extensions/tab_helper.h" 10 #include "chrome/browser/extensions/tab_helper.h"
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 base::SupportsUserData::Data* adoption_tag = 84 base::SupportsUserData::Data* adoption_tag =
85 web_contents->GetUserData(&kTabContentsAttachedTabHelpersUserDataKey); 85 web_contents->GetUserData(&kTabContentsAttachedTabHelpersUserDataKey);
86 if (adoption_tag) 86 if (adoption_tag)
87 return; 87 return;
88 88
89 // Mark as adopted. 89 // Mark as adopted.
90 web_contents->SetUserData(&kTabContentsAttachedTabHelpersUserDataKey, 90 web_contents->SetUserData(&kTabContentsAttachedTabHelpersUserDataKey,
91 new base::SupportsUserData::Data()); 91 new base::SupportsUserData::Data());
92 92
93 // Set the view type. 93 // Set the view type.
94 chrome::SetViewType(web_contents, chrome::VIEW_TYPE_TAB_CONTENTS); 94 chrome::SetViewType(web_contents, extensions::VIEW_TYPE_TAB_CONTENTS);
95 95
96 // Create all the tab helpers. 96 // Create all the tab helpers.
97 97
98 Profile* profile = 98 Profile* profile =
99 Profile::FromBrowserContext(web_contents->GetBrowserContext()); 99 Profile::FromBrowserContext(web_contents->GetBrowserContext());
100 100
101 // SessionTabHelper comes first because it sets up the tab ID, and other 101 // SessionTabHelper comes first because it sets up the tab ID, and other
102 // helpers may rely on that. 102 // helpers may rely on that.
103 SessionTabHelper::CreateForWebContents(web_contents); 103 SessionTabHelper::CreateForWebContents(web_contents);
104 104
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 if (OneClickSigninHelper::CanOffer( 173 if (OneClickSigninHelper::CanOffer(
174 web_contents, OneClickSigninHelper::CAN_OFFER_FOR_ALL, "", NULL)) { 174 web_contents, OneClickSigninHelper::CAN_OFFER_FOR_ALL, "", NULL)) {
175 OneClickSigninHelper::CreateForWebContents(web_contents); 175 OneClickSigninHelper::CreateForWebContents(web_contents);
176 } 176 }
177 #endif 177 #endif
178 178
179 #if defined(OS_WIN) 179 #if defined(OS_WIN)
180 MetroPinTabHelper::CreateForWebContents(web_contents); 180 MetroPinTabHelper::CreateForWebContents(web_contents);
181 #endif 181 #endif
182 } 182 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698