| OLD | NEW |
| 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 450 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 461 ChromeContentBrowserClient::ChromeContentBrowserClient() { | 461 ChromeContentBrowserClient::ChromeContentBrowserClient() { |
| 462 for (size_t i = 0; i < arraysize(kPredefinedAllowedSocketOrigins); ++i) | 462 for (size_t i = 0; i < arraysize(kPredefinedAllowedSocketOrigins); ++i) |
| 463 allowed_socket_origins_.insert(kPredefinedAllowedSocketOrigins[i]); | 463 allowed_socket_origins_.insert(kPredefinedAllowedSocketOrigins[i]); |
| 464 } | 464 } |
| 465 | 465 |
| 466 ChromeContentBrowserClient::~ChromeContentBrowserClient() { | 466 ChromeContentBrowserClient::~ChromeContentBrowserClient() { |
| 467 } | 467 } |
| 468 | 468 |
| 469 // static | 469 // static |
| 470 void ChromeContentBrowserClient::RegisterUserPrefs( | 470 void ChromeContentBrowserClient::RegisterUserPrefs( |
| 471 PrefRegistrySyncable* registry) { | 471 user_prefs::PrefRegistrySyncable* registry) { |
| 472 registry->RegisterBooleanPref(prefs::kDisable3DAPIs, | 472 registry->RegisterBooleanPref( |
| 473 false, | 473 prefs::kDisable3DAPIs, |
| 474 PrefRegistrySyncable::UNSYNCABLE_PREF); | 474 false, |
| 475 registry->RegisterBooleanPref(prefs::kEnableHyperlinkAuditing, | 475 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); |
| 476 true, | 476 registry->RegisterBooleanPref( |
| 477 PrefRegistrySyncable::UNSYNCABLE_PREF); | 477 prefs::kEnableHyperlinkAuditing, |
| 478 registry->RegisterBooleanPref(prefs::kEnableMemoryInfo, | 478 true, |
| 479 false, | 479 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); |
| 480 PrefRegistrySyncable::UNSYNCABLE_PREF); | 480 registry->RegisterBooleanPref( |
| 481 prefs::kEnableMemoryInfo, |
| 482 false, |
| 483 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); |
| 481 } | 484 } |
| 482 | 485 |
| 483 // static | 486 // static |
| 484 void ChromeContentBrowserClient::SetApplicationLocale( | 487 void ChromeContentBrowserClient::SetApplicationLocale( |
| 485 const std::string& locale) { | 488 const std::string& locale) { |
| 486 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); | 489 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
| 487 | 490 |
| 488 // This object is guaranteed to outlive all threads so we don't have to | 491 // This object is guaranteed to outlive all threads so we don't have to |
| 489 // worry about the lack of refcounting and can just post as Unretained. | 492 // worry about the lack of refcounting and can just post as Unretained. |
| 490 // | 493 // |
| (...skipping 1754 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2245 #if defined(USE_NSS) | 2248 #if defined(USE_NSS) |
| 2246 crypto::CryptoModuleBlockingPasswordDelegate* | 2249 crypto::CryptoModuleBlockingPasswordDelegate* |
| 2247 ChromeContentBrowserClient::GetCryptoPasswordDelegate( | 2250 ChromeContentBrowserClient::GetCryptoPasswordDelegate( |
| 2248 const GURL& url) { | 2251 const GURL& url) { |
| 2249 return chrome::NewCryptoModuleBlockingDialogDelegate( | 2252 return chrome::NewCryptoModuleBlockingDialogDelegate( |
| 2250 chrome::kCryptoModulePasswordKeygen, url.host()); | 2253 chrome::kCryptoModulePasswordKeygen, url.host()); |
| 2251 } | 2254 } |
| 2252 #endif | 2255 #endif |
| 2253 | 2256 |
| 2254 } // namespace chrome | 2257 } // namespace chrome |
| OLD | NEW |