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

Unified Diff: extensions/browser/api/bluetooth/bluetooth_private_api.cc

Issue 1464443002: bluetooth: android: Add BluetoothDevice::ConnectErrorCode enums (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: II Created 5 years, 1 month 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: extensions/browser/api/bluetooth/bluetooth_private_api.cc
diff --git a/extensions/browser/api/bluetooth/bluetooth_private_api.cc b/extensions/browser/api/bluetooth/bluetooth_private_api.cc
index 3ce90e54c8c854cdd38d359d689215b346d2c312..26f143c3e7e2742296b690b599114ab400824b8c 100644
--- a/extensions/browser/api/bluetooth/bluetooth_private_api.cc
+++ b/extensions/browser/api/bluetooth/bluetooth_private_api.cc
@@ -532,6 +532,27 @@ void BluetoothPrivateConnectFunction::OnErrorCallback(
case device::BluetoothDevice::ERROR_UNSUPPORTED_DEVICE:
result = bt_private::CONNECT_RESULT_TYPE_UNSUPPORTEDDEVICE;
break;
+ case device::BluetoothDevice::ERROR_ATTRIBUTE_LENGTH_INVALID:
+ result = bt_private::CONNECT_RESULT_TYPE_ATTRIBUTELENGTHINVALID;
+ break;
+ case device::BluetoothDevice::ERROR_CONNECTION_CONGESTED:
+ result = bt_private::CONNECT_RESULT_TYPE_CONNECTIONCONGESTED;
+ break;
+ case device::BluetoothDevice::ERROR_INSUFFICIENT_ENCRYPTION:
+ result = bt_private::CONNECT_RESULT_TYPE_INSUFFICIENTENCRYPTION;
+ break;
+ case device::BluetoothDevice::ERROR_OFFSET_INVALID:
+ result = bt_private::CONNECT_RESULT_TYPE_OFFSETINVALID;
+ break;
+ case device::BluetoothDevice::ERROR_READ_FAILED:
+ result = bt_private::CONNECT_RESULT_TYPE_READFAILED;
+ break;
+ case device::BluetoothDevice::ERROR_REQUEST_NOT_SUPPORTED:
+ result = bt_private::CONNECT_RESULT_TYPE_REQUESTNOTSUPPORTED;
+ break;
+ case device::BluetoothDevice::ERROR_WRITE_FAILED:
+ result = bt_private::CONNECT_RESULT_TYPE_WRITEFAILED;
+ break;
}
// Set the result type and respond with true (success).
results_ = bt_private::Connect::Results::Create(result);

Powered by Google App Engine
This is Rietveld 408576698