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

Unified Diff: components/arc/bluetooth/bluetooth_type_converters.h

Issue 2256003002: components/arc: implement multi advertising (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@plumb-incoming-connections
Patch Set: swap CHECK_EQ for EXPECT_EQ Created 4 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: components/arc/bluetooth/bluetooth_type_converters.h
diff --git a/components/arc/bluetooth/bluetooth_type_converters.h b/components/arc/bluetooth/bluetooth_type_converters.h
index 5c282dae78b523e4538f03f2f11d93b259c444e0..446770f142b3f2249c0c41a9b208e648dfa394d3 100644
--- a/components/arc/bluetooth/bluetooth_type_converters.h
+++ b/components/arc/bluetooth/bluetooth_type_converters.h
@@ -11,6 +11,7 @@
#include <utility>
#include "components/arc/common/bluetooth.mojom.h"
+#include "device/bluetooth/bluetooth_advertisement.h"
#include "device/bluetooth/bluetooth_gatt_service.h"
#include "mojo/public/cpp/bindings/type_converter.h"
rickyz (no longer on Chrome) 2016/08/24 21:47:30 I think the recommendation is to use type mapping
Eric Caruso 2016/08/24 22:24:42 Type mapping forces me to write the chrome->mojo c
rickyz (no longer on Chrome) 2016/08/29 01:09:23 I chatted with dcheng@, who asked one of the mojo
Eric Caruso 2016/08/29 17:24:52 I did actually look into this before and it gave m
@@ -49,6 +50,20 @@ struct TypeConverter<arc::mojom::BluetoothGattStatus,
const device::BluetoothGattService::GattErrorCode& error_code);
};
+template <>
+struct TypeConverter<device::BluetoothAdvertisement::AdvertisementType,
+ arc::mojom::BluetoothAdvertisementType> {
+ static device::BluetoothAdvertisement::AdvertisementType Convert(
+ const arc::mojom::BluetoothAdvertisementType& type);
+};
+
+template <>
+struct TypeConverter<std::unique_ptr<device::BluetoothAdvertisement::Data>,
+ arc::mojom::BluetoothAdvertisementPtr> {
+ static std::unique_ptr<device::BluetoothAdvertisement::Data> Convert(
+ const arc::mojom::BluetoothAdvertisementPtr& advertisement);
+};
+
} // namespace mojo
#endif // COMPONENTS_ARC_BLUETOOTH_BLUETOOTH_TYPE_CONVERTERS_H_

Powered by Google App Engine
This is Rietveld 408576698