summaryrefslogtreecommitdiff
path: root/chromium/remoting/client/input/BUILD.gn
blob: 17b12228207ac7ba79ad4233ba06461a01c907e0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
# Copyright 2014 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

source_set("input") {
  sources = [
    "client_input_injector.h",
    "direct_touch_input_strategy.cc",
    "direct_touch_input_strategy.h",
    "key_event_mapper.cc",
    "key_event_mapper.h",
    "keyboard_input_strategy.h",
    "keyboard_interpreter.cc",
    "keyboard_interpreter.h",
    "keycode_map.cc",
    "keycode_map.h",
    "native_device_keymap.cc",
    "native_device_keymap.h",
    "native_device_keymap_android.cc",
    "native_device_keymap_ios.cc",
    "text_keyboard_input_strategy.cc",
    "text_keyboard_input_strategy.h",
    "touch_input_scaler.cc",
    "touch_input_scaler.h",
    "touch_input_strategy.h",
    "trackpad_input_strategy.cc",
    "trackpad_input_strategy.h",
  ]

  deps = [
    ":normalizing_input_filter",
    "//remoting/base",
    "//remoting/client/ui:ui_manipulation",
    "//third_party/webrtc_overrides:webrtc_component",
    "//ui/events:dom_keycode_converter",
  ]

  if (is_android || is_ios) {
    sources -= [ "native_device_keymap.cc" ]
  }
}

source_set("normalizing_input_filter") {
  # Disabled the source filters because there are _mac files that need to
  # be compiled on all platforms.
  set_sources_assignment_filter([])
  sources = [
    "normalizing_input_filter_cros.cc",
    "normalizing_input_filter_cros.h",
    "normalizing_input_filter_mac.cc",
    "normalizing_input_filter_mac.h",
    "normalizing_input_filter_win.cc",
    "normalizing_input_filter_win.h",
  ]
  set_sources_assignment_filter(sources_assignment_filter)

  deps = [
    "//remoting/base",
    "//third_party/webrtc_overrides:webrtc_component",
    "//ui/events:dom_keycode_converter",
  ]
}

source_set("unit_tests") {
  testonly = true

  sources = [
    "key_event_mapper_unittest.cc",
    "keycode_map_unittest.cc",
    "touch_input_scaler_unittest.cc",
  ]

  configs += [
    "//remoting/build/config:version",
    "//remoting/build/config:enable_webrtc_remoting_client",
  ]

  deps = [
    ":input",
    ":normalizing_input_filter_unit_tests",
    "//remoting/proto",
    "//testing/gmock",
    "//testing/gtest",
    "//third_party/webrtc_overrides:webrtc_component",
  ]
}

source_set("normalizing_input_filter_unit_tests") {
  testonly = true

  set_sources_assignment_filter([])
  sources = [
    "normalizing_input_filter_cros_unittest.cc",
    "normalizing_input_filter_mac_unittest.cc",
    "normalizing_input_filter_win_unittest.cc",
  ]
  set_sources_assignment_filter(sources_assignment_filter)

  configs += [
    "//remoting/build/config:version",
    "//remoting/build/config:enable_webrtc_remoting_client",
  ]

  deps = [
    ":input",
    "//remoting/proto",
    "//testing/gmock",
    "//testing/gtest",
    "//third_party/webrtc_overrides:webrtc_component",
  ]
}