| 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 CHROME_BROWSER_CHROMEOS_DBUS_BLUETOOTH_AGENT_SERVICE_PROVIDER_H_ |    5 #ifndef CHROMEOS_DBUS_BLUETOOTH_AGENT_SERVICE_PROVIDER_H_ | 
|    6 #define CHROME_BROWSER_CHROMEOS_DBUS_BLUETOOTH_AGENT_SERVICE_PROVIDER_H_ |    6 #define CHROMEOS_DBUS_BLUETOOTH_AGENT_SERVICE_PROVIDER_H_ | 
|    7 #pragma once |    7 #pragma once | 
|    8  |    8  | 
|    9 #include <string> |    9 #include <string> | 
|   10  |   10  | 
|   11 #include "base/basictypes.h" |   11 #include "base/basictypes.h" | 
|   12 #include "base/callback.h" |   12 #include "base/callback.h" | 
 |   13 #include "chromeos/chromeos_export.h" | 
|   13 #include "dbus/bus.h" |   14 #include "dbus/bus.h" | 
|   14 #include "dbus/object_path.h" |   15 #include "dbus/object_path.h" | 
|   15  |   16  | 
|   16 namespace chromeos { |   17 namespace chromeos { | 
|   17  |   18  | 
|   18 // BluetoothAgentServiceProvider is used to provide a D-Bus object that BlueZ |   19 // BluetoothAgentServiceProvider is used to provide a D-Bus object that BlueZ | 
|   19 // can communicate with during a remote device pairing request. |   20 // can communicate with during a remote device pairing request. | 
|   20 // |   21 // | 
|   21 // Instantiate with a chosen D-Bus object path and delegate object, and pass |   22 // Instantiate with a chosen D-Bus object path and delegate object, and pass | 
|   22 // the D-Bus object path as the |agent_path| argument to the |   23 // the D-Bus object path as the |agent_path| argument to the | 
|   23 // chromeos::BluetoothAdapterClient::CreatePairedDevice() method. Calls made |   24 // chromeos::BluetoothAdapterClient::CreatePairedDevice() method. Calls made | 
|   24 // to the agent by the Bluetooth daemon will be passed on to your Delegate |   25 // to the agent by the Bluetooth daemon will be passed on to your Delegate | 
|   25 // object for handling, and responses returned using the callbacks supplied |   26 // object for handling, and responses returned using the callbacks supplied | 
|   26 // to those methods. |   27 // to those methods. | 
|   27 class BluetoothAgentServiceProvider { |   28 class CHROMEOS_EXPORT BluetoothAgentServiceProvider { | 
|   28  public: |   29  public: | 
|   29   // Interface for reacting to agent requests. |   30   // Interface for reacting to agent requests. | 
|   30   class Delegate { |   31   class Delegate { | 
|   31    public: |   32    public: | 
|   32     virtual ~Delegate() {} |   33     virtual ~Delegate() {} | 
|   33  |   34  | 
|   34     // Possible status values that may be returned to callbacks. Success |   35     // Possible status values that may be returned to callbacks. Success | 
|   35     // indicates that a pincode or passkey has been obtained, or permission |   36     // indicates that a pincode or passkey has been obtained, or permission | 
|   36     // granted; rejected indicates the user rejected the request or denied |   37     // granted; rejected indicates the user rejected the request or denied | 
|   37     // permission; cancelled indicates the user cancelled the request |   38     // permission; cancelled indicates the user cancelled the request | 
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  168  |  169  | 
|  169  protected: |  170  protected: | 
|  170   BluetoothAgentServiceProvider(); |  171   BluetoothAgentServiceProvider(); | 
|  171  |  172  | 
|  172  private: |  173  private: | 
|  173   DISALLOW_COPY_AND_ASSIGN(BluetoothAgentServiceProvider); |  174   DISALLOW_COPY_AND_ASSIGN(BluetoothAgentServiceProvider); | 
|  174 }; |  175 }; | 
|  175  |  176  | 
|  176 }  // namespace chromeos |  177 }  // namespace chromeos | 
|  177  |  178  | 
|  178 #endif  // CHROME_BROWSER_CHROMEOS_DBUS_BLUETOOTH_AGENT_SERVICE_PROVIDER_H_ |  179 #endif  // CHROMEOS_DBUS_BLUETOOTH_AGENT_SERVICE_PROVIDER_H_ | 
| OLD | NEW |