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

Side by Side Diff: chrome/browser/chrome_content_browser_client.cc

Issue 22912014: Correctly use IsThreadedCompositingEnabled in content_browsertests (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 4 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
« no previous file with comments | « no previous file | content/browser/browser_main_loop.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/chrome_content_browser_client.h" 5 #include "chrome/browser/chrome_content_browser_client.h"
6 6
7 #include <set> 7 #include <set>
8 #include <utility> 8 #include <utility>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 #include "chromeos/chromeos_constants.h" 108 #include "chromeos/chromeos_constants.h"
109 #include "components/nacl/common/nacl_process_type.h" 109 #include "components/nacl/common/nacl_process_type.h"
110 #include "components/user_prefs/pref_registry_syncable.h" 110 #include "components/user_prefs/pref_registry_syncable.h"
111 #include "content/public/browser/browser_child_process_host.h" 111 #include "content/public/browser/browser_child_process_host.h"
112 #include "content/public/browser/browser_main_parts.h" 112 #include "content/public/browser/browser_main_parts.h"
113 #include "content/public/browser/browser_ppapi_host.h" 113 #include "content/public/browser/browser_ppapi_host.h"
114 #include "content/public/browser/browser_thread.h" 114 #include "content/public/browser/browser_thread.h"
115 #include "content/public/browser/browser_url_handler.h" 115 #include "content/public/browser/browser_url_handler.h"
116 #include "content/public/browser/child_process_data.h" 116 #include "content/public/browser/child_process_data.h"
117 #include "content/public/browser/child_process_security_policy.h" 117 #include "content/public/browser/child_process_security_policy.h"
118 #include "content/public/browser/compositor_util.h"
119 #include "content/public/browser/render_process_host.h" 118 #include "content/public/browser/render_process_host.h"
120 #include "content/public/browser/render_view_host.h" 119 #include "content/public/browser/render_view_host.h"
121 #include "content/public/browser/resource_context.h" 120 #include "content/public/browser/resource_context.h"
122 #include "content/public/browser/site_instance.h" 121 #include "content/public/browser/site_instance.h"
123 #include "content/public/browser/web_contents.h" 122 #include "content/public/browser/web_contents.h"
124 #include "content/public/browser/web_contents_view.h" 123 #include "content/public/browser/web_contents_view.h"
125 #include "content/public/common/child_process_host.h" 124 #include "content/public/common/child_process_host.h"
126 #include "content/public/common/content_descriptors.h" 125 #include "content/public/common/content_descriptors.h"
127 #include "extensions/browser/view_type_utils.h" 126 #include "extensions/browser/view_type_utils.h"
128 #include "extensions/common/constants.h" 127 #include "extensions/common/constants.h"
(...skipping 1270 matching lines...) Expand 10 before | Expand all | Expand 10 after
1399 command_line->AppendSwitch(switches::kInstantProcess); 1398 command_line->AppendSwitch(switches::kInstantProcess);
1400 1399
1401 #if !defined(OS_CHROMEOS) 1400 #if !defined(OS_CHROMEOS)
1402 SigninManager* signin_manager = 1401 SigninManager* signin_manager =
1403 SigninManagerFactory::GetForProfile(profile); 1402 SigninManagerFactory::GetForProfile(profile);
1404 if (signin_manager && signin_manager->IsSigninProcess(process->GetID())) 1403 if (signin_manager && signin_manager->IsSigninProcess(process->GetID()))
1405 command_line->AppendSwitch(switches::kSigninProcess); 1404 command_line->AppendSwitch(switches::kSigninProcess);
1406 #endif 1405 #endif
1407 } 1406 }
1408 1407
1409 if (content::IsThreadedCompositingEnabled())
1410 command_line->AppendSwitch(switches::kEnableThreadedCompositing);
1411
1412 if (message_center::IsRichNotificationEnabled()) 1408 if (message_center::IsRichNotificationEnabled())
1413 command_line->AppendSwitch(switches::kDisableHTMLNotifications); 1409 command_line->AppendSwitch(switches::kDisableHTMLNotifications);
1414 1410
1415 // Please keep this in alphabetical order. 1411 // Please keep this in alphabetical order.
1416 static const char* const kSwitchNames[] = { 1412 static const char* const kSwitchNames[] = {
1417 autofill::switches::kDisableInteractiveAutocomplete, 1413 autofill::switches::kDisableInteractiveAutocomplete,
1418 autofill::switches::kEnableExperimentalFormFilling, 1414 autofill::switches::kEnableExperimentalFormFilling,
1419 autofill::switches::kEnableInteractiveAutocomplete, 1415 autofill::switches::kEnableInteractiveAutocomplete,
1420 extensions::switches::kAllowLegacyExtensionManifests, 1416 extensions::switches::kAllowLegacyExtensionManifests,
1421 extensions::switches::kAllowScriptingGallery, 1417 extensions::switches::kAllowScriptingGallery,
(...skipping 778 matching lines...) Expand 10 before | Expand all | Expand 10 after
2200 // Make sure we will set the default_encoding with canonical encoding name. 2196 // Make sure we will set the default_encoding with canonical encoding name.
2201 web_prefs->default_encoding = 2197 web_prefs->default_encoding =
2202 CharacterEncoding::GetCanonicalEncodingNameByAliasName( 2198 CharacterEncoding::GetCanonicalEncodingNameByAliasName(
2203 web_prefs->default_encoding); 2199 web_prefs->default_encoding);
2204 if (web_prefs->default_encoding.empty()) { 2200 if (web_prefs->default_encoding.empty()) {
2205 prefs->ClearPref(prefs::kDefaultCharset); 2201 prefs->ClearPref(prefs::kDefaultCharset);
2206 web_prefs->default_encoding = prefs->GetString(prefs::kDefaultCharset); 2202 web_prefs->default_encoding = prefs->GetString(prefs::kDefaultCharset);
2207 } 2203 }
2208 DCHECK(!web_prefs->default_encoding.empty()); 2204 DCHECK(!web_prefs->default_encoding.empty());
2209 2205
2210 if (content::IsForceCompositingModeEnabled())
2211 web_prefs->force_compositing_mode = true;
2212
2213 WebContents* web_contents = WebContents::FromRenderViewHost(rvh); 2206 WebContents* web_contents = WebContents::FromRenderViewHost(rvh);
2214 extensions::ViewType view_type = extensions::GetViewType(web_contents); 2207 extensions::ViewType view_type = extensions::GetViewType(web_contents);
2215 ExtensionService* service = 2208 ExtensionService* service =
2216 extensions::ExtensionSystem::Get(profile)->extension_service(); 2209 extensions::ExtensionSystem::Get(profile)->extension_service();
2217 if (service) { 2210 if (service) {
2218 const GURL& url = rvh->GetSiteInstance()->GetSiteURL(); 2211 const GURL& url = rvh->GetSiteInstance()->GetSiteURL();
2219 const Extension* extension = service->extensions()->GetByID(url.host()); 2212 const Extension* extension = service->extensions()->GetByID(url.host());
2220 // Ensure that we are only granting extension preferences to URLs with 2213 // Ensure that we are only granting extension preferences to URLs with
2221 // the correct scheme. Without this check, chrome-guest:// schemes used by 2214 // the correct scheme. Without this check, chrome-guest:// schemes used by
2222 // webview tags as well as hosts that happen to match the id of an 2215 // webview tags as well as hosts that happen to match the id of an
(...skipping 316 matching lines...) Expand 10 before | Expand all | Expand 10 after
2539 #if defined(USE_NSS) 2532 #if defined(USE_NSS)
2540 crypto::CryptoModuleBlockingPasswordDelegate* 2533 crypto::CryptoModuleBlockingPasswordDelegate*
2541 ChromeContentBrowserClient::GetCryptoPasswordDelegate( 2534 ChromeContentBrowserClient::GetCryptoPasswordDelegate(
2542 const GURL& url) { 2535 const GURL& url) {
2543 return chrome::NewCryptoModuleBlockingDialogDelegate( 2536 return chrome::NewCryptoModuleBlockingDialogDelegate(
2544 chrome::kCryptoModulePasswordKeygen, url.host()); 2537 chrome::kCryptoModulePasswordKeygen, url.host());
2545 } 2538 }
2546 #endif 2539 #endif
2547 2540
2548 } // namespace chrome 2541 } // namespace chrome
OLDNEW
« no previous file with comments | « no previous file | content/browser/browser_main_loop.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698