| 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 #ifndef DEVICE_BLUETOOTH_BLUETOOTH_INIT_WIN_H_ | 5 #ifndef DEVICE_BLUETOOTH_BLUETOOTH_INIT_WIN_H_ |
| 6 #define DEVICE_BLUETOOTH_BLUETOOTH_INIT_WIN_H_ | 6 #define DEVICE_BLUETOOTH_BLUETOOTH_INIT_WIN_H_ |
| 7 | 7 |
| 8 // windows.h needs to be included before BluetoothAPIs.h. | 8 // windows.h needs to be included before BluetoothAPIs.h. |
| 9 #include <windows.h> | 9 #include <windows.h> |
| 10 | 10 |
| 11 #include <BluetoothAPIs.h> | 11 #include <BluetoothAPIs.h> |
| 12 #if defined(_WIN32_WINNT_WIN8) && _MSC_VER < 1700 | 12 #if defined(_WIN32_WINNT_WIN8) && _MSC_VER < 1700 |
| 13 // The Windows 8 SDK defines FACILITY_VISUALCPP in winerror.h. | 13 // The Windows 8 SDK defines FACILITY_VISUALCPP in winerror.h. |
| 14 #undef FACILITY_VISUALCPP | 14 #undef FACILITY_VISUALCPP |
| 15 #endif | 15 #endif |
| 16 #include <delayimp.h> | 16 #include <delayimp.h> |
| 17 #include <ws2def.h> | 17 #include <ws2def.h> |
| 18 #include <ws2bth.h> | 18 #include <ws2bth.h> |
| 19 | 19 |
| 20 #include "device/bluetooth/bluetooth_export.h" |
| 21 |
| 20 #pragma comment(lib, "Bthprops.lib") | 22 #pragma comment(lib, "Bthprops.lib") |
| 21 #pragma comment(lib, "BluetoothApis.lib") | 23 #pragma comment(lib, "BluetoothApis.lib") |
| 22 | 24 |
| 23 namespace device { | 25 namespace device { |
| 24 namespace bluetooth_init_win { | 26 namespace bluetooth_init_win { |
| 25 | 27 |
| 26 // Returns true if the machine has a bluetooth stack available. The first call | 28 // Returns true if the machine has a bluetooth stack available. The first call |
| 27 // to this function will involve file IO, so it should be done on an appropriate | 29 // to this function will involve file IO, so it should be done on an appropriate |
| 28 // thread. This function is not thread-safe. | 30 // thread. This function is not thread-safe. |
| 29 bool HasBluetoothStack(); | 31 bool DEVICE_BLUETOOTH_EXPORT HasBluetoothStack(); |
| 30 | 32 |
| 31 } // namespace bluetooth_init_win | 33 } // namespace bluetooth_init_win |
| 32 } // namespace device | 34 } // namespace device |
| 33 | 35 |
| 34 #endif // DEVICE_BLUETOOTH_BLUETOOTH_INIT_WIN_H_ | 36 #endif // DEVICE_BLUETOOTH_BLUETOOTH_INIT_WIN_H_ |
| OLD | NEW |