OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 // Messages for Web Bluetooth API. | 5 // Messages for Web Bluetooth API. |
6 // Multiply-included message file, hence no include guard. | 6 // Multiply-included message file, hence no include guard. |
7 | 7 |
8 // Web Bluetooth Security | 8 // Web Bluetooth Security |
9 // The security mechanisms of Bluetooth are described in the specification: | 9 // The security mechanisms of Bluetooth are described in the specification: |
10 // https://webbluetoothchrome.github.io/web-bluetooth | 10 // https://webbluetoothchrome.github.io/web-bluetooth |
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
176 int /* thread_id */, | 176 int /* thread_id */, |
177 int /* request_id */) | 177 int /* request_id */) |
178 | 178 |
179 // Informs the renderer that an error occurred while writing a value to a | 179 // Informs the renderer that an error occurred while writing a value to a |
180 // characteristic. | 180 // characteristic. |
181 IPC_MESSAGE_CONTROL3(BluetoothMsg_WriteCharacteristicValueError, | 181 IPC_MESSAGE_CONTROL3(BluetoothMsg_WriteCharacteristicValueError, |
182 int /* thread_id */, | 182 int /* thread_id */, |
183 int /* request_id */, | 183 int /* request_id */, |
184 blink::WebBluetoothError /* result */) | 184 blink::WebBluetoothError /* result */) |
185 | 185 |
| 186 // Informs the renderer that the user has successfully subscribed to |
| 187 // notifications from the device. |
| 188 IPC_MESSAGE_CONTROL2(BluetoothMsg_StartNotificationsSuccess, |
| 189 int /* thread_id */, |
| 190 int /* request_id */) |
| 191 |
| 192 // Informs the renderer that an error ocurred when trying to subscribe to |
| 193 // notifications from the device. |
| 194 IPC_MESSAGE_CONTROL3(BluetoothMsg_StartNotificationsError, |
| 195 int /* thread_id */, |
| 196 int /* request_id */, |
| 197 blink::WebBluetoothError) |
| 198 |
| 199 // Informs the renderer that the user has successfully unsubscribed from |
| 200 // notifications. |
| 201 IPC_MESSAGE_CONTROL2(BluetoothMsg_StopNotificationsSuccess, |
| 202 int /* thread_id */, |
| 203 int /* request_id */) |
| 204 |
186 // Messages sent from the renderer to the browser. | 205 // Messages sent from the renderer to the browser. |
187 | 206 |
188 // Requests a bluetooth device from the browser. | 207 // Requests a bluetooth device from the browser. |
189 IPC_MESSAGE_CONTROL5(BluetoothHostMsg_RequestDevice, | 208 IPC_MESSAGE_CONTROL5(BluetoothHostMsg_RequestDevice, |
190 int /* thread_id */, | 209 int /* thread_id */, |
191 int /* request_id */, | 210 int /* request_id */, |
192 int /* frame_routing_id */, | 211 int /* frame_routing_id */, |
193 std::vector<content::BluetoothScanFilter>, | 212 std::vector<content::BluetoothScanFilter>, |
194 std::vector<device::BluetoothUUID> /* optional_services */) | 213 std::vector<device::BluetoothUUID> /* optional_services */) |
195 | 214 |
(...skipping 22 matching lines...) Expand all Loading... |
218 int /* thread_id */, | 237 int /* thread_id */, |
219 int /* request_id */, | 238 int /* request_id */, |
220 std::string /* characteristic_instance_id */) | 239 std::string /* characteristic_instance_id */) |
221 | 240 |
222 // Writes a value to a bluetooth device's characteristic. | 241 // Writes a value to a bluetooth device's characteristic. |
223 IPC_MESSAGE_CONTROL4(BluetoothHostMsg_WriteValue, | 242 IPC_MESSAGE_CONTROL4(BluetoothHostMsg_WriteValue, |
224 int /* thread_id */, | 243 int /* thread_id */, |
225 int /* request_id */, | 244 int /* request_id */, |
226 std::string /* characteristic_instance_id */, | 245 std::string /* characteristic_instance_id */, |
227 std::vector<uint8_t> /* value */) | 246 std::vector<uint8_t> /* value */) |
| 247 |
| 248 // Subscribes to notifications from a device's characteristic. |
| 249 IPC_MESSAGE_CONTROL3(BluetoothHostMsg_StartNotifications, |
| 250 int /* thread_id */, |
| 251 int /* request_id */, |
| 252 std::string /* characteristic_instance_id */) |
| 253 |
| 254 // Unsubscribes from notifications from a device's characteristic. |
| 255 IPC_MESSAGE_CONTROL3(BluetoothHostMsg_StopNotifications, |
| 256 int /* thread_id */, |
| 257 int /* request_id */, |
| 258 std::string /* characteristic_instance_id */) |
OLD | NEW |