Linux: Depend on liberation-fonts package for RPMs.
[chromium-blink-merge.git] / device / test / test_device_client.cc
blobf380c2cd04bcf6b83c72e009aab18a7ebf7ca2cb
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "device/test/test_device_client.h"
7 #include "device/hid/hid_service.h"
8 #include "device/usb/usb_service.h"
10 namespace device {
12 TestDeviceClient::TestDeviceClient(
13 scoped_refptr<base::SingleThreadTaskRunner> blocking_task_runner)
14 : blocking_task_runner_(blocking_task_runner) {}
16 TestDeviceClient::~TestDeviceClient() {}
18 HidService* TestDeviceClient::GetHidService() {
19 #if !defined(OS_ANDROID) && !defined(OS_IOS) && \
20 !(defined(OS_LINUX) && !defined(USE_UDEV))
21 if (!hid_service_) {
22 hid_service_ = HidService::Create(blocking_task_runner_);
24 #endif
25 return hid_service_.get();
28 UsbService* TestDeviceClient::GetUsbService() {
29 #if !defined(OS_ANDROID) && !defined(OS_IOS)
30 if (!usb_service_) {
31 usb_service_ = UsbService::Create(blocking_task_runner_);
33 #endif
34 return usb_service_.get();
37 } // namespace device