Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(426)

Side by Side Diff: device/battery/BUILD.gn

Issue 457933002: Replace Chrome IPC with Mojo IPC for querying BatteryStatus service Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 # Copyright 2014 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.
4
5 import("//build/config/features.gni")
6 import("//mojo/public/tools/bindings/mojom.gni")
7
8 component("battery") {
9 output_name = "device_battery"
10
11 sources = [
12 "battery_export.h",
13 "battery_monitor_impl.cc",
14 "battery_monitor_impl.h",
15 "battery_status_manager_android.cc",
16 "battery_status_manager_android.h",
17 "battery_status_manager_chromeos.cc",
18 "battery_status_manager_default.cc",
19 "battery_status_manager_linux.cc",
20 "battery_status_manager_linux.h",
21 "battery_status_manager_mac.cc",
22 "battery_status_manager_win.cc",
23 "battery_status_manager_win.h",
24 "battery_status_service.cc",
25 "battery_status_service.h",
26 ]
27
28 defines = [
29 "DEVICE_BATTERY_IMPLEMENTATION",
30 ]
31
32 deps = [
33 ":mojo_bindings",
34 "//base",
35 "//base/third_party/dynamic_annotations",
36 "//mojo/environment:chromium",
37 "//mojo/public/cpp/bindings",
38 "//mojo/system",
39 ]
40
41 if (is_chromeos) {
42 configs += [
43 "//build/config/linux:dbus",
44 ]
45 deps += [
46 "//chromeos:power_manager_proto",
47 ]
48 sources -= [
49 "battery_status_manager_default.cc",
50 "battery_status_manager_linux.cc",
51 ]
52 }
53
54 if (is_linux) {
55 if (use_dbus) {
56 configs += [
57 "//build/config/linux:dbus",
58 ]
59 deps += [
60 "//dbus"
61 ]
62 sources -= [
63 "battery_status_manager_default.cc",
64 ]
65 } else {
66 sources -= [
67 "battery_status_manager_linux.cc",
68 ]
69 }
70 }
71
72 if (is_mac) {
73 sources -= [
74 "battery_status_manager_default.cc",
75 ]
76 }
77
78 if (is_win) {
79 sources -= [
80 "battery_status_manager_default.cc",
81 ]
82 }
83 }
84
85 mojom("mojo_bindings") {
86 sources = [
87 "battery_monitor.mojom",
88 "battery_status.mojom",
89 ]
90 }
OLDNEW
« no previous file with comments | « content/test/data/battery_status/battery_status_promise_resolution_test.html ('k') | device/battery/DEPS » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698