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 "chromeos/dbus/bluetooth_agent_service_provider.h" | 5 #include "chromeos/dbus/bluetooth_agent_service_provider.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/chromeos/chromeos_version.h" | |
11 #include "base/logging.h" | 10 #include "base/logging.h" |
12 #include "base/memory/ref_counted.h" | 11 #include "base/memory/ref_counted.h" |
| 12 #include "base/sys_info.h" |
13 #include "base/threading/platform_thread.h" | 13 #include "base/threading/platform_thread.h" |
14 #include "chromeos/dbus/fake_bluetooth_agent_service_provider.h" | 14 #include "chromeos/dbus/fake_bluetooth_agent_service_provider.h" |
15 #include "dbus/bus.h" | 15 #include "dbus/bus.h" |
16 #include "dbus/exported_object.h" | 16 #include "dbus/exported_object.h" |
17 #include "dbus/message.h" | 17 #include "dbus/message.h" |
18 #include "dbus/object_path.h" | 18 #include "dbus/object_path.h" |
19 #include "third_party/cros_system_api/dbus/service_constants.h" | 19 #include "third_party/cros_system_api/dbus/service_constants.h" |
20 | 20 |
21 namespace chromeos { | 21 namespace chromeos { |
22 | 22 |
(...skipping 439 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
462 } | 462 } |
463 | 463 |
464 BluetoothAgentServiceProvider::~BluetoothAgentServiceProvider() { | 464 BluetoothAgentServiceProvider::~BluetoothAgentServiceProvider() { |
465 } | 465 } |
466 | 466 |
467 // static | 467 // static |
468 BluetoothAgentServiceProvider* BluetoothAgentServiceProvider::Create( | 468 BluetoothAgentServiceProvider* BluetoothAgentServiceProvider::Create( |
469 dbus::Bus* bus, | 469 dbus::Bus* bus, |
470 const dbus::ObjectPath& object_path, | 470 const dbus::ObjectPath& object_path, |
471 Delegate* delegate) { | 471 Delegate* delegate) { |
472 if (base::chromeos::IsRunningOnChromeOS()) { | 472 if (base::SysInfo::IsRunningOnChromeOS()) { |
473 return new BluetoothAgentServiceProviderImpl(bus, object_path, delegate); | 473 return new BluetoothAgentServiceProviderImpl(bus, object_path, delegate); |
474 } else { | 474 } else { |
475 return new FakeBluetoothAgentServiceProvider(object_path, delegate); | 475 return new FakeBluetoothAgentServiceProvider(object_path, delegate); |
476 } | 476 } |
477 } | 477 } |
478 | 478 |
479 } // namespace chromeos | 479 } // namespace chromeos |
OLD | NEW |