| 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/bluetooth_device_mac.h" | 5 #include "device/bluetooth/bluetooth_device_mac.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/hash.h" | 10 #include "base/hash.h" |
| (...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 215 const ErrorCallback& error_callback) { | 215 const ErrorCallback& error_callback) { |
| 216 NOTIMPLEMENTED(); | 216 NOTIMPLEMENTED(); |
| 217 } | 217 } |
| 218 | 218 |
| 219 void BluetoothDeviceMac::ClearOutOfBandPairingData( | 219 void BluetoothDeviceMac::ClearOutOfBandPairingData( |
| 220 const base::Closure& callback, | 220 const base::Closure& callback, |
| 221 const ErrorCallback& error_callback) { | 221 const ErrorCallback& error_callback) { |
| 222 NOTIMPLEMENTED(); | 222 NOTIMPLEMENTED(); |
| 223 } | 223 } |
| 224 | 224 |
| 225 void BluetoothDeviceMac::StartConnectionMonitor( |
| 226 const base::Closure& callback, |
| 227 const ErrorCallback& error_callback) { |
| 228 NOTIMPLEMENTED(); |
| 229 } |
| 230 |
| 231 void BluetoothDeviceMac::StopConnectionMonitor( |
| 232 const base::Closure& callback, |
| 233 const ErrorCallback& error_callback) { |
| 234 NOTIMPLEMENTED(); |
| 235 } |
| 236 |
| 225 int BluetoothDeviceMac::GetHostTransmitPower( | 237 int BluetoothDeviceMac::GetHostTransmitPower( |
| 226 BluetoothHCITransmitPowerLevelType power_level_type) const { | 238 BluetoothHCITransmitPowerLevelType power_level_type) const { |
| 227 IOBluetoothHostController* controller = | 239 IOBluetoothHostController* controller = |
| 228 [IOBluetoothHostController defaultController]; | 240 [IOBluetoothHostController defaultController]; |
| 229 | 241 |
| 230 // Bail if the undocumented API is unavailable on this machine. | 242 // Bail if the undocumented API is unavailable on this machine. |
| 231 SEL selector = @selector( | 243 SEL selector = @selector( |
| 232 BluetoothHCIReadTransmitPowerLevel:inType:outTransmitPowerLevel:); | 244 BluetoothHCIReadTransmitPowerLevel:inType:outTransmitPowerLevel:); |
| 233 if (![controller respondsToSelector:selector]) | 245 if (![controller respondsToSelector:selector]) |
| 234 return kUnknownPower; | 246 return kUnknownPower; |
| (...skipping 16 matching lines...) Expand all Loading... |
| 251 | 263 |
| 252 // static | 264 // static |
| 253 std::string BluetoothDeviceMac::NormalizeAddress(const std::string& address) { | 265 std::string BluetoothDeviceMac::NormalizeAddress(const std::string& address) { |
| 254 std::string normalized; | 266 std::string normalized; |
| 255 base::ReplaceChars(address, "-", ":", &normalized); | 267 base::ReplaceChars(address, "-", ":", &normalized); |
| 256 StringToUpperASCII(&normalized); | 268 StringToUpperASCII(&normalized); |
| 257 return normalized; | 269 return normalized; |
| 258 } | 270 } |
| 259 | 271 |
| 260 } // namespace device | 272 } // namespace device |
| OLD | NEW |