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

Side by Side Diff: content/shell/browser/shell_browser_context.cc

Issue 384413004: Remove default key slot from KeygenHandler. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 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 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 "content/shell/browser/shell_browser_context.h" 5 #include "content/shell/browser/shell_browser_context.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/environment.h" 9 #include "base/environment.h"
10 #include "base/file_util.h" 10 #include "base/file_util.h"
11 #include "base/logging.h" 11 #include "base/logging.h"
12 #include "base/path_service.h" 12 #include "base/path_service.h"
13 #include "base/threading/thread.h" 13 #include "base/threading/thread.h"
14 #include "content/public/browser/browser_thread.h" 14 #include "content/public/browser/browser_thread.h"
15 #include "content/public/browser/resource_context.h" 15 #include "content/public/browser/resource_context.h"
16 #include "content/public/browser/storage_partition.h" 16 #include "content/public/browser/storage_partition.h"
17 #include "content/public/common/content_switches.h" 17 #include "content/public/common/content_switches.h"
18 #include "content/shell/browser/shell_download_manager_delegate.h" 18 #include "content/shell/browser/shell_download_manager_delegate.h"
19 #include "content/shell/browser/shell_url_request_context_getter.h" 19 #include "content/shell/browser/shell_url_request_context_getter.h"
20 #include "content/shell/common/shell_switches.h" 20 #include "content/shell/common/shell_switches.h"
21 #include "net/base/keygen_handler.h"
21 22
22 #if defined(OS_WIN) 23 #if defined(OS_WIN)
23 #include "base/base_paths_win.h" 24 #include "base/base_paths_win.h"
24 #elif defined(OS_LINUX) 25 #elif defined(OS_LINUX)
25 #include "base/nix/xdg_util.h" 26 #include "base/nix/xdg_util.h"
26 #elif defined(OS_MACOSX) 27 #elif defined(OS_MACOSX)
27 #include "base/base_paths_mac.h" 28 #include "base/base_paths_mac.h"
28 #endif 29 #endif
29 30
30 namespace content { 31 namespace content {
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 InitWhileIOAllowed(); 71 InitWhileIOAllowed();
71 } 72 }
72 73
73 ShellBrowserContext::~ShellBrowserContext() { 74 ShellBrowserContext::~ShellBrowserContext() {
74 if (resource_context_) { 75 if (resource_context_) {
75 BrowserThread::DeleteSoon( 76 BrowserThread::DeleteSoon(
76 BrowserThread::IO, FROM_HERE, resource_context_.release()); 77 BrowserThread::IO, FROM_HERE, resource_context_.release());
77 } 78 }
78 } 79 }
79 80
81 void ShellBrowserContext::CreateKeygenHandler(
82 uint32 key_size_in_bits,
83 const std::string& challenge_string,
84 const GURL& url,
85 const base::Callback<void(scoped_ptr<net::KeygenHandler>)>& callback) {
86 scoped_ptr<net::KeygenHandler> handler(
87 new net::KeygenHandler(key_size_in_bits, challenge_string, url));
88 }
89
80 void ShellBrowserContext::InitWhileIOAllowed() { 90 void ShellBrowserContext::InitWhileIOAllowed() {
81 CommandLine* cmd_line = CommandLine::ForCurrentProcess(); 91 CommandLine* cmd_line = CommandLine::ForCurrentProcess();
82 if (cmd_line->HasSwitch(switches::kIgnoreCertificateErrors) || 92 if (cmd_line->HasSwitch(switches::kIgnoreCertificateErrors) ||
83 cmd_line->HasSwitch(switches::kDumpRenderTree)) { 93 cmd_line->HasSwitch(switches::kDumpRenderTree)) {
84 ignore_certificate_errors_ = true; 94 ignore_certificate_errors_ = true;
85 } 95 }
86 if (cmd_line->HasSwitch(switches::kContentShellDataPath)) { 96 if (cmd_line->HasSwitch(switches::kContentShellDataPath)) {
87 path_ = cmd_line->GetSwitchValuePath(switches::kContentShellDataPath); 97 path_ = cmd_line->GetSwitchValuePath(switches::kContentShellDataPath);
88 return; 98 return;
89 } 99 }
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
198 208
199 quota::SpecialStoragePolicy* ShellBrowserContext::GetSpecialStoragePolicy() { 209 quota::SpecialStoragePolicy* ShellBrowserContext::GetSpecialStoragePolicy() {
200 return NULL; 210 return NULL;
201 } 211 }
202 212
203 PushMessagingService* ShellBrowserContext::GetPushMessagingService() { 213 PushMessagingService* ShellBrowserContext::GetPushMessagingService() {
204 return NULL; 214 return NULL;
205 } 215 }
206 216
207 } // namespace content 217 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698