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 #include "device/bluetooth/dbus/bluetooth_device_client.h" | 5 #include "device/bluetooth/dbus/bluetooth_device_client.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
80 break; | 80 break; |
81 } | 81 } |
82 case bluez::BluetoothServiceAttributeValueBlueZ::UUID: | 82 case bluez::BluetoothServiceAttributeValueBlueZ::UUID: |
83 // Fall through. | 83 // Fall through. |
84 case bluez::BluetoothServiceAttributeValueBlueZ::STRING: | 84 case bluez::BluetoothServiceAttributeValueBlueZ::STRING: |
85 // Fall through. | 85 // Fall through. |
86 case bluez::BluetoothServiceAttributeValueBlueZ::URL: { | 86 case bluez::BluetoothServiceAttributeValueBlueZ::URL: { |
87 std::string str; | 87 std::string str; |
88 if (!struct_reader->PopVariantOfString(&str)) | 88 if (!struct_reader->PopVariantOfString(&str)) |
89 return nullptr; | 89 return nullptr; |
90 value = base::MakeUnique<base::StringValue>(str); | 90 value = base::MakeUnique<base::Value>(str); |
91 break; | 91 break; |
92 } | 92 } |
93 case bluez::BluetoothServiceAttributeValueBlueZ::BOOL: { | 93 case bluez::BluetoothServiceAttributeValueBlueZ::BOOL: { |
94 bool b; | 94 bool b; |
95 if (!struct_reader->PopVariantOfBool(&b)) | 95 if (!struct_reader->PopVariantOfBool(&b)) |
96 return nullptr; | 96 return nullptr; |
97 value = base::MakeUnique<base::Value>(b); | 97 value = base::MakeUnique<base::Value>(b); |
98 break; | 98 break; |
99 } | 99 } |
100 case bluez::BluetoothServiceAttributeValueBlueZ::SEQUENCE: { | 100 case bluez::BluetoothServiceAttributeValueBlueZ::SEQUENCE: { |
(...skipping 465 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
566 | 566 |
567 BluetoothDeviceClient::BluetoothDeviceClient() {} | 567 BluetoothDeviceClient::BluetoothDeviceClient() {} |
568 | 568 |
569 BluetoothDeviceClient::~BluetoothDeviceClient() {} | 569 BluetoothDeviceClient::~BluetoothDeviceClient() {} |
570 | 570 |
571 BluetoothDeviceClient* BluetoothDeviceClient::Create() { | 571 BluetoothDeviceClient* BluetoothDeviceClient::Create() { |
572 return new BluetoothDeviceClientImpl(); | 572 return new BluetoothDeviceClientImpl(); |
573 } | 573 } |
574 | 574 |
575 } // namespace bluez | 575 } // namespace bluez |
OLD | NEW |