| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 // From ppb_udp_socket.idl modified Fri Mar 13 17:49:57 2015. | 5 // From ppb_udp_socket.idl modified Fri Mar 4 14:31:30 2016. |
| 6 | |
| 7 #include <stdint.h> | |
| 8 | 6 |
| 9 #include "ppapi/c/pp_completion_callback.h" | 7 #include "ppapi/c/pp_completion_callback.h" |
| 10 #include "ppapi/c/pp_errors.h" | 8 #include "ppapi/c/pp_errors.h" |
| 11 #include "ppapi/c/ppb_udp_socket.h" | 9 #include "ppapi/c/ppb_udp_socket.h" |
| 12 #include "ppapi/shared_impl/tracked_callback.h" | 10 #include "ppapi/shared_impl/tracked_callback.h" |
| 13 #include "ppapi/thunk/enter.h" | 11 #include "ppapi/thunk/enter.h" |
| 14 #include "ppapi/thunk/ppapi_thunk_export.h" | 12 #include "ppapi/thunk/ppapi_thunk_export.h" |
| 15 #include "ppapi/thunk/ppb_udp_socket_api.h" | 13 #include "ppapi/thunk/ppb_udp_socket_api.h" |
| 16 | 14 |
| 17 namespace ppapi { | 15 namespace ppapi { |
| (...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 134 int32_t LeaveGroup(PP_Resource udp_socket, | 132 int32_t LeaveGroup(PP_Resource udp_socket, |
| 135 PP_Resource group, | 133 PP_Resource group, |
| 136 struct PP_CompletionCallback callback) { | 134 struct PP_CompletionCallback callback) { |
| 137 VLOG(4) << "PPB_UDPSocket::LeaveGroup()"; | 135 VLOG(4) << "PPB_UDPSocket::LeaveGroup()"; |
| 138 EnterResource<PPB_UDPSocket_API> enter(udp_socket, callback, true); | 136 EnterResource<PPB_UDPSocket_API> enter(udp_socket, callback, true); |
| 139 if (enter.failed()) | 137 if (enter.failed()) |
| 140 return enter.retval(); | 138 return enter.retval(); |
| 141 return enter.SetResult(enter.object()->LeaveGroup(group, enter.callback())); | 139 return enter.SetResult(enter.object()->LeaveGroup(group, enter.callback())); |
| 142 } | 140 } |
| 143 | 141 |
| 144 const PPB_UDPSocket_1_0 g_ppb_udpsocket_thunk_1_0 = {&Create, | 142 const PPB_UDPSocket_1_0 g_ppb_udpsocket_thunk_1_0 = { |
| 145 &IsUDPSocket, | 143 &Create, &IsUDPSocket, &Bind, &GetBoundAddress, |
| 146 &Bind, | 144 &RecvFrom, &SendTo, &Close, &SetOption_1_0}; |
| 147 &GetBoundAddress, | |
| 148 &RecvFrom, | |
| 149 &SendTo, | |
| 150 &Close, | |
| 151 &SetOption_1_0}; | |
| 152 | 145 |
| 153 const PPB_UDPSocket_1_1 g_ppb_udpsocket_thunk_1_1 = {&Create, | 146 const PPB_UDPSocket_1_1 g_ppb_udpsocket_thunk_1_1 = { |
| 154 &IsUDPSocket, | 147 &Create, &IsUDPSocket, &Bind, &GetBoundAddress, |
| 155 &Bind, | 148 &RecvFrom, &SendTo, &Close, &SetOption_1_1}; |
| 156 &GetBoundAddress, | |
| 157 &RecvFrom, | |
| 158 &SendTo, | |
| 159 &Close, | |
| 160 &SetOption_1_1}; | |
| 161 | 149 |
| 162 const PPB_UDPSocket_1_2 g_ppb_udpsocket_thunk_1_2 = {&Create, | 150 const PPB_UDPSocket_1_2 g_ppb_udpsocket_thunk_1_2 = { |
| 163 &IsUDPSocket, | 151 &Create, &IsUDPSocket, &Bind, &GetBoundAddress, &RecvFrom, |
| 164 &Bind, | 152 &SendTo, &Close, &SetOption, &JoinGroup, &LeaveGroup}; |
| 165 &GetBoundAddress, | |
| 166 &RecvFrom, | |
| 167 &SendTo, | |
| 168 &Close, | |
| 169 &SetOption, | |
| 170 &JoinGroup, | |
| 171 &LeaveGroup}; | |
| 172 | 153 |
| 173 } // namespace | 154 } // namespace |
| 174 | 155 |
| 175 PPAPI_THUNK_EXPORT const PPB_UDPSocket_1_0* GetPPB_UDPSocket_1_0_Thunk() { | 156 PPAPI_THUNK_EXPORT const PPB_UDPSocket_1_0* GetPPB_UDPSocket_1_0_Thunk() { |
| 176 return &g_ppb_udpsocket_thunk_1_0; | 157 return &g_ppb_udpsocket_thunk_1_0; |
| 177 } | 158 } |
| 178 | 159 |
| 179 PPAPI_THUNK_EXPORT const PPB_UDPSocket_1_1* GetPPB_UDPSocket_1_1_Thunk() { | 160 PPAPI_THUNK_EXPORT const PPB_UDPSocket_1_1* GetPPB_UDPSocket_1_1_Thunk() { |
| 180 return &g_ppb_udpsocket_thunk_1_1; | 161 return &g_ppb_udpsocket_thunk_1_1; |
| 181 } | 162 } |
| 182 | 163 |
| 183 PPAPI_THUNK_EXPORT const PPB_UDPSocket_1_2* GetPPB_UDPSocket_1_2_Thunk() { | 164 PPAPI_THUNK_EXPORT const PPB_UDPSocket_1_2* GetPPB_UDPSocket_1_2_Thunk() { |
| 184 return &g_ppb_udpsocket_thunk_1_2; | 165 return &g_ppb_udpsocket_thunk_1_2; |
| 185 } | 166 } |
| 186 | 167 |
| 187 } // namespace thunk | 168 } // namespace thunk |
| 188 } // namespace ppapi | 169 } // namespace ppapi |
| OLD | NEW |