summaryrefslogtreecommitdiff
path: root/chromium/chrome/browser/media/router/BUILD.gn
blob: 9ffad961491eff05687c356105a6fac90370f1c5 (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
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
# Copyright 2015 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.
#

import("//extensions/features/features.gni")
import("//testing/test.gni")

static_library("router") {
  deps = [
    "//base",
    "//chrome/common:constants",
    "//components/keyed_service/content",
    "//components/keyed_service/core",
    "//content/public/browser",
    "//content/public/common",
    "//net",
    "//third_party/icu",
    "//url",
  ]
  public_deps = [
    "//chrome/common/media_router:router",
  ]
  sources = [
    "browser_presentation_connection_proxy.cc",
    "browser_presentation_connection_proxy.h",
    "issue_manager.cc",
    "issue_manager.h",
    "issues_observer.cc",
    "issues_observer.h",
    "media_router.h",
    "media_router_base.cc",
    "media_router_base.h",
    "media_router_dialog_controller.cc",
    "media_router_dialog_controller.h",
    "media_router_factory.cc",
    "media_router_factory.h",
    "media_router_metrics.cc",
    "media_router_metrics.h",
    "media_routes_observer.cc",
    "media_routes_observer.h",
    "media_sinks_observer.cc",
    "media_sinks_observer.h",
    "offscreen_presentation_manager.cc",
    "offscreen_presentation_manager.h",
    "offscreen_presentation_manager_factory.cc",
    "offscreen_presentation_manager_factory.h",
    "presentation_media_sinks_observer.cc",
    "presentation_media_sinks_observer.h",
    "presentation_service_delegate_impl.cc",
    "presentation_service_delegate_impl.h",
    "presentation_service_delegate_observers.cc",
    "presentation_service_delegate_observers.h",
    "receiver_presentation_service_delegate_impl.cc",
    "receiver_presentation_service_delegate_impl.h",
    "render_frame_host_id.h",
    "route_message_observer.cc",
    "route_message_observer.h",
  ]

  if (enable_extensions) {
    deps += [
      "discovery",
      "//extensions/browser",
      "//mojo/public/cpp/bindings",
    ]
    sources += [
      "event_page_request_manager.cc",
      "event_page_request_manager.h",
      "event_page_request_manager_factory.cc",
      "event_page_request_manager_factory.h",

      # TODO(crbug.com/646627): Move media_router_ui_service* to
      # chrome/browser/ui/.
      "media_router_ui_service.cc",
      "media_router_ui_service.h",
      "media_router_ui_service_factory.cc",
      "media_router_ui_service_factory.h",
      "mojo/extension_media_route_provider_proxy.cc",
      "mojo/extension_media_route_provider_proxy.h",
      "mojo/media_route_controller.cc",
      "mojo/media_route_controller.h",
      "mojo/media_route_provider_util_win.cc",
      "mojo/media_route_provider_util_win.h",
      "mojo/media_router_desktop.cc",
      "mojo/media_router_desktop.h",
      "mojo/media_router_mojo_impl.cc",
      "mojo/media_router_mojo_impl.h",
      "mojo/media_router_mojo_metrics.cc",
      "mojo/media_router_mojo_metrics.h",
    ]
  }
}

static_library("test_support") {
  testonly = true
  deps = [
    "//chrome/test:test_support",
    "//testing/gmock",
  ]
  public_deps = [
    ":router",
  ]
  sources = [
    "mock_media_router.cc",
    "mock_media_router.h",
    "mock_screen_availability_listener.cc",
    "mock_screen_availability_listener.h",
    "test_helper.cc",
    "test_helper.h",
  ]

  if (enable_extensions) {
    deps += [
      "discovery",
      "//chrome/common/media_router/mojo:media_router",
      "//chrome/common/media_router/mojo:media_router_test_interfaces",
      "//extensions/browser",
      "//extensions/common",
    ]
    sources += [
      "discovery/mdns/mock_dns_sd_registry.cc",
      "discovery/mdns/mock_dns_sd_registry.h",
      "mojo/media_router_mojo_test.cc",
      "mojo/media_router_mojo_test.h",
    ]
  }
}