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

Side by Side Diff: ppapi/cpp/private/network_monitor_private.cc

Issue 9545010: Add NetworkList/NetworkMonitor hooks and C++ wrappers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: - Created 8 years, 9 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 | « ppapi/cpp/private/network_monitor_private.h ('k') | ppapi/ppapi_shared.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "ppapi/cpp/private/network_monitor_private.h"
6
7 #include "ppapi/cpp/instance.h"
8 #include "ppapi/cpp/module_impl.h"
9
10 namespace pp {
11
12 namespace {
13
14 template <> const char* interface_name<PPB_NetworkMonitor_Private>() {
15 return PPB_NETWORKMONITOR_PRIVATE_INTERFACE;
16 }
17
18 } // namespace
19
20 NetworkMonitorPrivate::NetworkMonitorPrivate(
21 const InstanceHandle& instance,
22 PPB_NetworkMonitor_Callback callback,
23 void* user_data) {
24 if (has_interface<PPB_NetworkMonitor_Private>()) {
25 PassRefFromConstructor(get_interface<PPB_NetworkMonitor_Private>()->Create(
26 instance.pp_instance(), callback, user_data));
27 }
28 }
29
30 // static
31 bool NetworkMonitorPrivate::IsAvailable() {
32 return has_interface<PPB_NetworkMonitor_Private>();
33 }
34
35 } // namespace pp
OLDNEW
« no previous file with comments | « ppapi/cpp/private/network_monitor_private.h ('k') | ppapi/ppapi_shared.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698