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

Side by Side Diff: content/child/webkitplatformsupport_impl.cc

Issue 22815034: Introduce webkit_glue bridges for the new WebSocket Implementation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 2 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
« no previous file with comments | « content/child/webkitplatformsupport_impl.h ('k') | content/child/websocket_bridge.h » ('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 "base/command_line.h" 5 #include "base/command_line.h"
6 #include "content/child/child_thread.h" 6 #include "content/child/child_thread.h"
7 #include "content/child/socket_stream_dispatcher.h" 7 #include "content/child/socket_stream_dispatcher.h"
8 #include "content/child/webkitplatformsupport_impl.h" 8 #include "content/child/webkitplatformsupport_impl.h"
9 #include "content/child/websocket_bridge.h"
9 #include "content/public/common/content_client.h" 10 #include "content/public/common/content_client.h"
10 11
11 namespace content { 12 namespace content {
12 13
13 WebKitPlatformSupportImpl::WebKitPlatformSupportImpl() { 14 WebKitPlatformSupportImpl::WebKitPlatformSupportImpl() {
14 } 15 }
15 16
16 WebKitPlatformSupportImpl::~WebKitPlatformSupportImpl() { 17 WebKitPlatformSupportImpl::~WebKitPlatformSupportImpl() {
17 } 18 }
18 19
19 string16 WebKitPlatformSupportImpl::GetLocalizedString(int message_id) { 20 string16 WebKitPlatformSupportImpl::GetLocalizedString(int message_id) {
20 return GetContentClient()->GetLocalizedString(message_id); 21 return GetContentClient()->GetLocalizedString(message_id);
21 } 22 }
22 23
23 base::StringPiece WebKitPlatformSupportImpl::GetDataResource( 24 base::StringPiece WebKitPlatformSupportImpl::GetDataResource(
24 int resource_id, 25 int resource_id,
25 ui::ScaleFactor scale_factor) { 26 ui::ScaleFactor scale_factor) {
26 return GetContentClient()->GetDataResource(resource_id, scale_factor); 27 return GetContentClient()->GetDataResource(resource_id, scale_factor);
27 } 28 }
28 29
29 webkit_glue::ResourceLoaderBridge* 30 webkit_glue::ResourceLoaderBridge*
30 WebKitPlatformSupportImpl::CreateResourceLoader( 31 WebKitPlatformSupportImpl::CreateResourceLoader(
31 const webkit_glue::ResourceLoaderBridge::RequestInfo& request_info) { 32 const webkit_glue::ResourceLoaderBridge::RequestInfo& request_info) {
32 return ChildThread::current()->CreateBridge(request_info); 33 return ChildThread::current()->CreateBridge(request_info);
33 } 34 }
34 35
35 webkit_glue::WebSocketStreamHandleBridge* 36 webkit_glue::WebSocketStreamHandleBridge*
36 WebKitPlatformSupportImpl::CreateWebSocketBridge( 37 WebKitPlatformSupportImpl::CreateWebSocketStreamBridge(
37 WebKit::WebSocketStreamHandle* handle, 38 WebKit::WebSocketStreamHandle* handle,
38 webkit_glue::WebSocketStreamHandleDelegate* delegate) { 39 webkit_glue::WebSocketStreamHandleDelegate* delegate) {
39 SocketStreamDispatcher* dispatcher = 40 SocketStreamDispatcher* dispatcher =
40 ChildThread::current()->socket_stream_dispatcher(); 41 ChildThread::current()->socket_stream_dispatcher();
41 return dispatcher->CreateBridge(handle, delegate); 42 return dispatcher->CreateBridge(handle, delegate);
42 } 43 }
43 44
45 WebKit::WebSocketHandle* WebKitPlatformSupportImpl::createWebSocketHandle() {
46 return new WebSocketBridge;
47 }
48
44 } // namespace content 49 } // namespace content
OLDNEW
« no previous file with comments | « content/child/webkitplatformsupport_impl.h ('k') | content/child/websocket_bridge.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698