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

Side by Side Diff: chrome/browser/signin/signin_header_helper.cc

Issue 1066563006: GuestView: Move GuestViewManager extension dependencies to ExtensionsGuestViewManagerDelegate (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@extensions_guest_view_message_filter
Patch Set: Fixed NavigateGuest Created 5 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/signin/signin_header_helper.h" 5 #include "chrome/browser/signin/signin_header_helper.h"
6 6
7 #include "base/strings/string_number_conversions.h" 7 #include "base/strings/string_number_conversions.h"
8 #include "base/strings/string_util.h" 8 #include "base/strings/string_util.h"
9 #include "base/strings/stringprintf.h" 9 #include "base/strings/stringprintf.h"
10 #include "chrome/browser/prefs/incognito_mode_prefs.h" 10 #include "chrome/browser/prefs/incognito_mode_prefs.h"
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after
243 243
244 #if !defined(OS_ANDROID) && !defined(OS_IOS) 244 #if !defined(OS_ANDROID) && !defined(OS_IOS)
245 extensions::WebViewRendererState::WebViewInfo webview_info; 245 extensions::WebViewRendererState::WebViewInfo webview_info;
246 bool is_guest = extensions::WebViewRendererState::GetInstance()->GetInfo( 246 bool is_guest = extensions::WebViewRendererState::GetInstance()->GetInfo(
247 child_id, route_id, &webview_info); 247 child_id, route_id, &webview_info);
248 // Do not set the x-chrome-connected header on requests from a native signin 248 // Do not set the x-chrome-connected header on requests from a native signin
249 // webview, as identified by an empty extension id which means the webview is 249 // webview, as identified by an empty extension id which means the webview is
250 // embedded in a webui page, otherwise user may end up with a blank page as 250 // embedded in a webui page, otherwise user may end up with a blank page as
251 // gaia uses the header to decide whether it returns 204 for certain end 251 // gaia uses the header to decide whether it returns 204 for certain end
252 // points. 252 // points.
253 if (is_guest && webview_info.owner_extension_id.empty()) 253 if (is_guest && webview_info.owner_host.empty())
254 return false; 254 return false;
255 #endif // !OS_ANDROID && !OS_IOS 255 #endif // !OS_ANDROID && !OS_IOS
256 256
257 int profile_mode_mask = PROFILE_MODE_DEFAULT; 257 int profile_mode_mask = PROFILE_MODE_DEFAULT;
258 if (io_data->incognito_availibility()->GetValue() == 258 if (io_data->incognito_availibility()->GetValue() ==
259 IncognitoModePrefs::DISABLED || 259 IncognitoModePrefs::DISABLED ||
260 IncognitoModePrefs::ArePlatformParentalControlsEnabled()) { 260 IncognitoModePrefs::ArePlatformParentalControlsEnabled()) {
261 profile_mode_mask |= PROFILE_MODE_INCOGNITO_DISABLED; 261 profile_mode_mask |= PROFILE_MODE_INCOGNITO_DISABLED;
262 } 262 }
263 263
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
301 301
302 params.child_id = child_id; 302 params.child_id = child_id;
303 params.route_id = route_id; 303 params.route_id = route_id;
304 content::BrowserThread::PostTask( 304 content::BrowserThread::PostTask(
305 content::BrowserThread::UI, FROM_HERE, 305 content::BrowserThread::UI, FROM_HERE,
306 base::Bind(ProcessMirrorHeaderUIThread, child_id, route_id, params)); 306 base::Bind(ProcessMirrorHeaderUIThread, child_id, route_id, params));
307 #endif // defined(OS_IOS) 307 #endif // defined(OS_IOS)
308 } 308 }
309 309
310 } // namespace signin 310 } // namespace signin
OLDNEW
« no previous file with comments | « chrome/browser/profiles/profile_impl.cc ('k') | chrome/browser/ui/tab_contents/core_tab_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698