OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "components/pairing/bluetooth_host_pairing_controller.h" | 5 #include "components/pairing/bluetooth_host_pairing_controller.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/hash.h" | 8 #include "base/hash.h" |
9 #include "base/location.h" | 9 #include "base/location.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
| 11 #include "base/single_thread_task_runner.h" |
11 #include "base/strings/stringprintf.h" | 12 #include "base/strings/stringprintf.h" |
12 #include "base/task_runner_util.h" | 13 #include "base/task_runner_util.h" |
13 #include "chromeos/system/devicetype.h" | 14 #include "chromeos/system/devicetype.h" |
14 #include "components/pairing/bluetooth_pairing_constants.h" | 15 #include "components/pairing/bluetooth_pairing_constants.h" |
15 #include "components/pairing/pairing_api.pb.h" | 16 #include "components/pairing/pairing_api.pb.h" |
16 #include "components/pairing/proto_decoder.h" | 17 #include "components/pairing/proto_decoder.h" |
17 #include "device/bluetooth/bluetooth_adapter_factory.h" | 18 #include "device/bluetooth/bluetooth_adapter_factory.h" |
18 #include "net/base/io_buffer.h" | 19 #include "net/base/io_buffer.h" |
19 | 20 |
20 namespace pairing_chromeos { | 21 namespace pairing_chromeos { |
(...skipping 535 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
556 ChangeStage(STAGE_WAITING_FOR_CODE_CONFIRMATION); | 557 ChangeStage(STAGE_WAITING_FOR_CODE_CONFIRMATION); |
557 } | 558 } |
558 | 559 |
559 void BluetoothHostPairingController::AuthorizePairing( | 560 void BluetoothHostPairingController::AuthorizePairing( |
560 device::BluetoothDevice* device) { | 561 device::BluetoothDevice* device) { |
561 // Disallow unknown device. | 562 // Disallow unknown device. |
562 device->RejectPairing(); | 563 device->RejectPairing(); |
563 } | 564 } |
564 | 565 |
565 } // namespace pairing_chromeos | 566 } // namespace pairing_chromeos |
OLD | NEW |