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

Side by Side Diff: webkit/plugins/ppapi/ppb_tcp_socket_private_impl.cc

Issue 12220050: Provide a way to disable Nagle's algorithm on Pepper TCP sockets. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase. Created 7 years, 10 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 | « webkit/plugins/ppapi/ppb_tcp_socket_private_impl.h ('k') | no next file » | 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 "webkit/plugins/ppapi/ppb_tcp_socket_private_impl.h" 5 #include "webkit/plugins/ppapi/ppb_tcp_socket_private_impl.h"
6 6
7 #include "webkit/plugins/ppapi/host_globals.h" 7 #include "webkit/plugins/ppapi/host_globals.h"
8 #include "webkit/plugins/ppapi/plugin_delegate.h" 8 #include "webkit/plugins/ppapi/plugin_delegate.h"
9 #include "webkit/plugins/ppapi/ppapi_plugin_instance.h" 9 #include "webkit/plugins/ppapi/ppapi_plugin_instance.h"
10 #include "webkit/plugins/ppapi/resource_helper.h" 10 #include "webkit/plugins/ppapi/resource_helper.h"
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 } 103 }
104 104
105 void PPB_TCPSocket_Private_Impl::SendDisconnect() { 105 void PPB_TCPSocket_Private_Impl::SendDisconnect() {
106 PluginDelegate* plugin_delegate = ResourceHelper::GetPluginDelegate(this); 106 PluginDelegate* plugin_delegate = ResourceHelper::GetPluginDelegate(this);
107 if (!plugin_delegate) 107 if (!plugin_delegate)
108 return; 108 return;
109 109
110 plugin_delegate->TCPSocketDisconnect(socket_id_); 110 plugin_delegate->TCPSocketDisconnect(socket_id_);
111 } 111 }
112 112
113 void PPB_TCPSocket_Private_Impl::SendSetBoolOption(
114 PP_TCPSocketOption_Private name,
115 bool value) {
116 PluginDelegate* plugin_delegate = ResourceHelper::GetPluginDelegate(this);
117 if (!plugin_delegate)
118 return;
119
120 plugin_delegate->TCPSocketSetBoolOption(socket_id_, name, value);
121 }
122
113 PluginDelegate* PPB_TCPSocket_Private_Impl::GetPluginDelegate( 123 PluginDelegate* PPB_TCPSocket_Private_Impl::GetPluginDelegate(
114 PP_Instance instance) { 124 PP_Instance instance) {
115 PluginInstance* plugin_instance = HostGlobals::Get()->GetInstance(instance); 125 PluginInstance* plugin_instance = HostGlobals::Get()->GetInstance(instance);
116 if (!plugin_instance) 126 if (!plugin_instance)
117 return NULL; 127 return NULL;
118 return plugin_instance->delegate(); 128 return plugin_instance->delegate();
119 } 129 }
120 130
121 } // namespace ppapi 131 } // namespace ppapi
122 } // namespace webkit 132 } // namespace webkit
OLDNEW
« no previous file with comments | « webkit/plugins/ppapi/ppb_tcp_socket_private_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698