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

Unified Diff: ppapi/shared_impl/private/udp_socket_private_impl.h

Issue 10735056: AllowBroadcast() is exposed to NaCl. (Closed) Base URL: http://git.chromium.org/chromium/src.git@udp_broadcast
Patch Set: Fixed comments. Created 8 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: ppapi/shared_impl/private/udp_socket_private_impl.h
diff --git a/ppapi/shared_impl/private/udp_socket_private_impl.h b/ppapi/shared_impl/private/udp_socket_private_impl.h
index 36d51ca0e94b45ac4ea38ba305ba1e4f773451fe..16c6939073708ed382d9e2103d56a6f1d4747e33 100644
--- a/ppapi/shared_impl/private/udp_socket_private_impl.h
+++ b/ppapi/shared_impl/private/udp_socket_private_impl.h
@@ -40,6 +40,10 @@ class PPAPI_SHARED_EXPORT UDPSocketPrivateImpl
virtual PPB_UDPSocket_Private_API* AsPPB_UDPSocket_Private_API() OVERRIDE;
// PPB_UDPSocket_Private_API implementation.
+ virtual int32_t SetSocketFeature(
+ PP_UDPSocketFeature_Private name,
+ PP_Var value,
+ scoped_refptr<TrackedCallback> callback) OVERRIDE;
virtual int32_t Bind(const PP_NetAddress_Private* addr,
scoped_refptr<TrackedCallback> callback) OVERRIDE;
virtual PP_Bool GetBoundAddress(PP_NetAddress_Private* addr) OVERRIDE;
@@ -54,6 +58,7 @@ class PPAPI_SHARED_EXPORT UDPSocketPrivateImpl
virtual void Close() OVERRIDE;
// Notifications from the proxy.
+ void OnSetSocketFeatureCompleted(bool succeeded);
void OnBindCompleted(bool succeeded,
const PP_NetAddress_Private& bound_addr);
void OnRecvFromCompleted(bool succeeded,
@@ -63,6 +68,8 @@ class PPAPI_SHARED_EXPORT UDPSocketPrivateImpl
// Send functions that need to be implemented differently for
// the proxied and non-proxied derived classes.
+ virtual void SendSetSocketFeature(PP_UDPSocketFeature_Private name,
+ PP_Var value) = 0;
virtual void SendBind(const PP_NetAddress_Private& addr) = 0;
virtual void SendRecvFrom(int32_t num_bytes) = 0;
virtual void SendSendTo(const std::string& buffer,
@@ -78,6 +85,7 @@ class PPAPI_SHARED_EXPORT UDPSocketPrivateImpl
bool bound_;
bool closed_;
+ scoped_refptr<TrackedCallback> setsocketfeature_callback_;
scoped_refptr<TrackedCallback> bind_callback_;
scoped_refptr<TrackedCallback> recvfrom_callback_;
scoped_refptr<TrackedCallback> sendto_callback_;

Powered by Google App Engine
This is Rietveld 408576698