| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/bluetooth_task_manager_win.h" | 5 #include "device/bluetooth/bluetooth_task_manager_win.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <winsock2.h> | 8 #include <winsock2.h> |
| 9 | 9 |
| 10 #include <string> | 10 #include <string> |
| (...skipping 516 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 527 if ((*iter)->is_bluetooth_classic()) { | 527 if ((*iter)->is_bluetooth_classic()) { |
| 528 if (!DiscoverClassicDeviceServices(device->address, | 528 if (!DiscoverClassicDeviceServices(device->address, |
| 529 L2CAP_PROTOCOL_UUID, | 529 L2CAP_PROTOCOL_UUID, |
| 530 search_cached_services_only, | 530 search_cached_services_only, |
| 531 service_record_states)) { | 531 service_record_states)) { |
| 532 return false; | 532 return false; |
| 533 } | 533 } |
| 534 } else { | 534 } else { |
| 535 if (!DiscoverLowEnergyDeviceServices(device->path, | 535 if (!DiscoverLowEnergyDeviceServices(device->path, |
| 536 service_record_states)) { | 536 service_record_states)) { |
| 537 return SearchForGattServiceDevicePaths(device->address, | 537 return false; |
| 538 service_record_states); | 538 } |
| 539 if (!SearchForGattServiceDevicePaths(device->address, |
| 540 service_record_states)) { |
| 541 return false; |
| 539 } | 542 } |
| 540 } | 543 } |
| 541 } | 544 } |
| 542 return true; | 545 return true; |
| 543 } | 546 } |
| 544 | 547 |
| 545 bool BluetoothTaskManagerWin::DiscoverClassicDeviceServices( | 548 bool BluetoothTaskManagerWin::DiscoverClassicDeviceServices( |
| 546 const std::string& device_address, | 549 const std::string& device_address, |
| 547 const GUID& protocol_uuid, | 550 const GUID& protocol_uuid, |
| 548 bool search_cached_services_only, | 551 bool search_cached_services_only, |
| (...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 718 break; | 721 break; |
| 719 } | 722 } |
| 720 } | 723 } |
| 721 } | 724 } |
| 722 } | 725 } |
| 723 | 726 |
| 724 return true; | 727 return true; |
| 725 } | 728 } |
| 726 | 729 |
| 727 } // namespace device | 730 } // namespace device |
| OLD | NEW |