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

Side by Side Diff: content/renderer/pepper/pepper_plugin_delegate_impl.h

Issue 11411357: PPB_HostResolver_Private is switched to the new Pepper proxy. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed MockPluginDelegate. Created 8 years 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 (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 #ifndef CONTENT_RENDERER_PEPPER_PEPPER_PLUGIN_DELEGATE_IMPL_H_ 5 #ifndef CONTENT_RENDERER_PEPPER_PEPPER_PLUGIN_DELEGATE_IMPL_H_
6 #define CONTENT_RENDERER_PEPPER_PEPPER_PLUGIN_DELEGATE_IMPL_H_ 6 #define CONTENT_RENDERER_PEPPER_PEPPER_PLUGIN_DELEGATE_IMPL_H_
7 7
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
11 #include <vector> 11 #include <vector>
12 12
13 #include "base/basictypes.h" 13 #include "base/basictypes.h"
14 #include "base/id_map.h" 14 #include "base/id_map.h"
15 #include "base/memory/ref_counted.h" 15 #include "base/memory/ref_counted.h"
16 #include "base/memory/scoped_ptr.h" 16 #include "base/memory/scoped_ptr.h"
17 #include "base/memory/weak_ptr.h" 17 #include "base/memory/weak_ptr.h"
18 #include "base/observer_list.h" 18 #include "base/observer_list.h"
19 #include "content/public/renderer/render_view_observer.h" 19 #include "content/public/renderer/render_view_observer.h"
20 #include "content/renderer/mouse_lock_dispatcher.h" 20 #include "content/renderer/mouse_lock_dispatcher.h"
21 #include "content/renderer/pepper/pepper_parent_context_provider.h" 21 #include "content/renderer/pepper/pepper_parent_context_provider.h"
22 #include "content/renderer/render_view_pepper_helper.h" 22 #include "content/renderer/render_view_pepper_helper.h"
23 #include "ppapi/shared_impl/private/ppb_host_resolver_shared.h"
24 #include "ppapi/shared_impl/private/ppb_tcp_server_socket_shared.h" 23 #include "ppapi/shared_impl/private/ppb_tcp_server_socket_shared.h"
25 #include "ppapi/shared_impl/private/tcp_socket_private_impl.h" 24 #include "ppapi/shared_impl/private/tcp_socket_private_impl.h"
26 #include "ppapi/shared_impl/private/udp_socket_private_impl.h" 25 #include "ppapi/shared_impl/private/udp_socket_private_impl.h"
27 #include "ui/base/ime/text_input_type.h" 26 #include "ui/base/ime/text_input_type.h"
28 #include "webkit/plugins/ppapi/plugin_delegate.h" 27 #include "webkit/plugins/ppapi/plugin_delegate.h"
29 28
30 class FilePath; 29 class FilePath;
31 30
32 namespace IPC { 31 namespace IPC {
33 struct ChannelHandle; 32 struct ChannelHandle;
(...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after
285 const PP_NetAddress_Private& addr) OVERRIDE; 284 const PP_NetAddress_Private& addr) OVERRIDE;
286 virtual void UDPSocketClose(uint32 socket_id) OVERRIDE; 285 virtual void UDPSocketClose(uint32 socket_id) OVERRIDE;
287 virtual void TCPServerSocketListen( 286 virtual void TCPServerSocketListen(
288 PP_Resource socket_resource, 287 PP_Resource socket_resource,
289 const PP_NetAddress_Private& addr, 288 const PP_NetAddress_Private& addr,
290 int32_t backlog) OVERRIDE; 289 int32_t backlog) OVERRIDE;
291 virtual void TCPServerSocketAccept(uint32 server_socket_id) OVERRIDE; 290 virtual void TCPServerSocketAccept(uint32 server_socket_id) OVERRIDE;
292 virtual void TCPServerSocketStopListening( 291 virtual void TCPServerSocketStopListening(
293 PP_Resource socket_resource, 292 PP_Resource socket_resource,
294 uint32 socket_id) OVERRIDE; 293 uint32 socket_id) OVERRIDE;
295 virtual void RegisterHostResolver(
296 ppapi::PPB_HostResolver_Shared* host_resolver,
297 uint32 host_resolver_id) OVERRIDE;
298 virtual void HostResolverResolve(
299 uint32 host_resolver_id,
300 const ::ppapi::HostPortPair& host_port,
301 const PP_HostResolver_Private_Hint* hint) OVERRIDE;
302 virtual void UnregisterHostResolver(uint32 host_resolver_id) OVERRIDE;
303 virtual bool AddNetworkListObserver( 294 virtual bool AddNetworkListObserver(
304 webkit_glue::NetworkListObserver* observer) OVERRIDE; 295 webkit_glue::NetworkListObserver* observer) OVERRIDE;
305 virtual void RemoveNetworkListObserver( 296 virtual void RemoveNetworkListObserver(
306 webkit_glue::NetworkListObserver* observer) OVERRIDE; 297 webkit_glue::NetworkListObserver* observer) OVERRIDE;
307 virtual bool X509CertificateParseDER( 298 virtual bool X509CertificateParseDER(
308 const std::vector<char>& der, 299 const std::vector<char>& der,
309 ppapi::PPB_X509Certificate_Fields* fields) OVERRIDE; 300 ppapi::PPB_X509Certificate_Fields* fields) OVERRIDE;
310 virtual webkit::ppapi::FullscreenContainer* 301 virtual webkit::ppapi::FullscreenContainer*
311 CreateFullscreenContainer( 302 CreateFullscreenContainer(
312 webkit::ppapi::PluginInstance* instance) OVERRIDE; 303 webkit::ppapi::PluginInstance* instance) OVERRIDE;
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
376 const PP_NetAddress_Private& addr); 367 const PP_NetAddress_Private& addr);
377 void OnTCPServerSocketListenACK(uint32 plugin_dispatcher_id, 368 void OnTCPServerSocketListenACK(uint32 plugin_dispatcher_id,
378 PP_Resource socket_resource, 369 PP_Resource socket_resource,
379 uint32 socket_id, 370 uint32 socket_id,
380 int32_t status); 371 int32_t status);
381 void OnTCPServerSocketAcceptACK(uint32 plugin_dispatcher_id, 372 void OnTCPServerSocketAcceptACK(uint32 plugin_dispatcher_id,
382 uint32 socket_id, 373 uint32 socket_id,
383 uint32 accepted_socket_id, 374 uint32 accepted_socket_id,
384 const PP_NetAddress_Private& local_addr, 375 const PP_NetAddress_Private& local_addr,
385 const PP_NetAddress_Private& remote_addr); 376 const PP_NetAddress_Private& remote_addr);
386 void OnHostResolverResolveACK(
387 uint32 plugin_dispatcher_id,
388 uint32 host_resolver_id,
389 bool succeeded,
390 const std::string& canonical_name,
391 const std::vector<PP_NetAddress_Private>& net_address_list);
392 377
393 // Attempts to create a PPAPI plugin for the given filepath. On success, it 378 // Attempts to create a PPAPI plugin for the given filepath. On success, it
394 // will return the newly-created module. 379 // will return the newly-created module.
395 // 380 //
396 // There are two reasons for failure. The first is that the plugin isn't 381 // There are two reasons for failure. The first is that the plugin isn't
397 // a PPAPI plugin. In this case, |*pepper_plugin_was_registered| will be set 382 // a PPAPI plugin. In this case, |*pepper_plugin_was_registered| will be set
398 // to false and the caller may want to fall back on creating an NPAPI plugin. 383 // to false and the caller may want to fall back on creating an NPAPI plugin.
399 // the second is that the plugin failed to initialize. In this case, 384 // the second is that the plugin failed to initialize. In this case,
400 // |*pepper_plugin_was_registered| will be set to true and the caller should 385 // |*pepper_plugin_was_registered| will be set to true and the caller should
401 // not fall back on any other plugin types. 386 // not fall back on any other plugin types.
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
438 LockTargetMap mouse_lock_instances_; 423 LockTargetMap mouse_lock_instances_;
439 424
440 IDMap<AsyncOpenFileCallback> pending_async_open_files_; 425 IDMap<AsyncOpenFileCallback> pending_async_open_files_;
441 426
442 IDMap<webkit::ppapi::PPB_TCPSocket_Private_Impl> tcp_sockets_; 427 IDMap<webkit::ppapi::PPB_TCPSocket_Private_Impl> tcp_sockets_;
443 428
444 IDMap<webkit::ppapi::PPB_UDPSocket_Private_Impl> udp_sockets_; 429 IDMap<webkit::ppapi::PPB_UDPSocket_Private_Impl> udp_sockets_;
445 430
446 IDMap<ppapi::PPB_TCPServerSocket_Shared> tcp_server_sockets_; 431 IDMap<ppapi::PPB_TCPServerSocket_Shared> tcp_server_sockets_;
447 432
448 IDMap<ppapi::PPB_HostResolver_Shared> host_resolvers_;
449
450 typedef IDMap<scoped_refptr<PepperBrokerImpl>, IDMapOwnPointer> BrokerMap; 433 typedef IDMap<scoped_refptr<PepperBrokerImpl>, IDMapOwnPointer> BrokerMap;
451 BrokerMap pending_connect_broker_; 434 BrokerMap pending_connect_broker_;
452 435
453 typedef IDMap<base::WeakPtr<webkit::ppapi::PPB_Broker_Impl> > 436 typedef IDMap<base::WeakPtr<webkit::ppapi::PPB_Broker_Impl> >
454 PermissionRequestMap; 437 PermissionRequestMap;
455 PermissionRequestMap pending_permission_requests_; 438 PermissionRequestMap pending_permission_requests_;
456 439
457 // Whether or not the focus is on a PPAPI plugin 440 // Whether or not the focus is on a PPAPI plugin
458 webkit::ppapi::PluginInstance* focused_plugin_; 441 webkit::ppapi::PluginInstance* focused_plugin_;
459 442
(...skipping 11 matching lines...) Expand all
471 454
472 scoped_ptr<PepperDeviceEnumerationEventHandler> 455 scoped_ptr<PepperDeviceEnumerationEventHandler>
473 device_enumeration_event_handler_; 456 device_enumeration_event_handler_;
474 457
475 DISALLOW_COPY_AND_ASSIGN(PepperPluginDelegateImpl); 458 DISALLOW_COPY_AND_ASSIGN(PepperPluginDelegateImpl);
476 }; 459 };
477 460
478 } // namespace content 461 } // namespace content
479 462
480 #endif // CONTENT_RENDERER_PEPPER_PEPPER_PLUGIN_DELEGATE_IMPL_H_ 463 #endif // CONTENT_RENDERER_PEPPER_PEPPER_PLUGIN_DELEGATE_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698