Commit 69c1aef3 authored by Christopher Lam's avatar Christopher Lam Committed by Commit Bot

Convert ChromeOS resources Closure Compile to GN.

See go/closure-compile-gn for details.

This CL converts the Closure Compilation of ChromeOS resources from GYP to
GN.

A local closure compile can be run by setting closure_compile = true in
args.gn, and then running ninja -C out/Default webui_closure_compile.
A more localized compile may look like:
ninja -C out/Default chrome/browser/resources/chromeos:closure_compile

TBR=dpranke@chromium.org, dpapad@chromium.org
TEST=Running the compilation with a type mismatch should cause a failure.

Bug: 632206
Cq-Include-Trybots: master.tryserver.chromium.linux:closure_compilation
Change-Id: If1656b63a5571a00f54a913d5295231970eba44e
Reviewed-on: https://chromium-review.googlesource.com/1049350
Commit-Queue: calamity <calamity@chromium.org>
Reviewed-by: default avatarAchuith Bhandarkar <achuith@chromium.org>
Cr-Commit-Position: refs/heads/master@{#566316}
parent 300c6052
......@@ -1583,8 +1583,8 @@ group("extra_resources") {
public_deps += [
"//chrome/browser/resources/chromeos:multidevice_setup_resources",
"//chrome/browser/resources/chromeos/chromevox",
"//chrome/browser/resources/chromeos/select_to_speak",
"//chrome/browser/resources/chromeos/switch_access",
"//chrome/browser/resources/chromeos/select_to_speak:build",
"//chrome/browser/resources/chromeos/switch_access:build",
]
}
......
......@@ -27,6 +27,7 @@ if (closure_compile) {
}
if (is_chromeos) {
deps += [
"chromeos:closure_compile",
"md_user_manager:closure_compile",
"signin/dice_sync_confirmation:closure_compile",
"welcome/dice_welcome:closure_compile",
......
......@@ -3,6 +3,7 @@
# found in the LICENSE file.
import("//chrome/common/features.gni")
import("//third_party/closure_compiler/compile_js.gni")
import("//tools/grit/grit_rule.gni")
assert(is_chromeos, "Only Chrome OS resources in //c/b/resources//chromeos.")
......@@ -19,3 +20,18 @@ grit("multidevice_setup_resources") {
]
output_dir = "$root_gen_dir/chrome"
}
group("closure_compile") {
deps = [
"bluetooth_pairing_dialog:closure_compile",
"braille_ime:closure_compile",
"internet_config_dialog:closure_compile",
"internet_detail_dialog:closure_compile",
"login:closure_compile",
"multidevice_setup:closure_compile",
"network_ui:closure_compile",
"select_to_speak:closure_compile",
"switch_access:closure_compile",
"sys_internals:closure_compile",
]
}
# Copyright 2018 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("//third_party/closure_compiler/compile_js.gni")
import("../../optimize_webui.gni")
optimize_webui("build") {
......@@ -10,3 +15,24 @@ optimize_webui("build") {
deps = []
}
js_type_check("closure_compile") {
deps = [
":bluetooth_pairing_dialog",
]
}
js_library("bluetooth_pairing_dialog") {
deps = [
"//ui/webui/resources/js:cr",
"//ui/webui/resources/js:i18n_behavior",
]
externs_list = [
"$externs_path/bluetooth.js",
"$externs_path/bluetooth_private.js",
]
extra_sources = [
"$interfaces_path/bluetooth_interface.js",
"$interfaces_path/bluetooth_private_interface.js",
]
}
# Copyright 2018 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.
{
'targets': [
{
'target_name': 'bluetooth_pairing_dialog',
'dependencies': [
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:cr',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:i18n_behavior',
'<(EXTERNS_GYP):bluetooth',
'<(EXTERNS_GYP):bluetooth_private',
'<(INTERFACES_GYP):bluetooth_interface',
'<(INTERFACES_GYP):bluetooth_private_interface',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
],
}
# Copyright 2015 The Chromium Authors. All rights reserved.
# Copyright 2018 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("//third_party/closure_compiler/compile_js.gni")
assert(is_chromeos)
copy("braille_ime_manifest") {
......@@ -12,3 +14,23 @@ copy("braille_ime_manifest") {
"$root_out_dir/resources/chromeos/braille_ime/manifest.json",
]
}
js_type_check("closure_compile") {
deps = [
":braille_ime",
":main",
]
}
js_library("braille_ime") {
externs_list = [
"$externs_path/chrome_extensions.js",
"externs.js",
]
}
js_library("main") {
deps = [
":braille_ime",
]
}
# Copyright 2016 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.
{
'targets': [
{
'target_name': 'braille_ime',
'dependencies': [
'<(EXTERNS_GYP):chrome_extensions',
'externs',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'externs',
'includes': ['../../../../../third_party/closure_compiler/include_js.gypi'],
},
{
'target_name': 'main',
'dependencies': [
'braille_ime',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
],
}
# Copyright 2018 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("//third_party/closure_compiler/compile_js.gni")
js_type_check("closure_compile") {
deps = [
":chrome_extension_externs",
]
}
js_library("chrome_extension_externs") {
}
# Copyright 2016 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.
{
'targets': [
{
'target_name': 'chrome_extension_externs',
'includes': ['../../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
],
}
# Copyright 2017 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.
{
'targets': [
{
'target_name': 'chromeos_resources',
'type': 'none',
'dependencies': [
'bluetooth_pairing_dialog/compiled_resources2.gyp:*',
'internet_config_dialog/compiled_resources2.gyp:*',
'internet_detail_dialog/compiled_resources2.gyp:*',
],
},
]
}
# Copyright 2018 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("../../optimize_webui.gni")
import("//third_party/closure_compiler/compile_js.gni")
optimize_webui("build") {
host = "internet_config_dialog"
......@@ -10,3 +15,25 @@ optimize_webui("build") {
deps = []
}
js_type_check("closure_compile") {
deps = [
":internet_config_dialog",
]
}
js_library("internet_config_dialog") {
deps = [
"//ui/webui/resources/cr_components/chromeos/network:network_config",
"//ui/webui/resources/cr_elements/chromeos/network:cr_onc_types",
"//ui/webui/resources/cr_elements/cr_dialog:cr_dialog",
"//ui/webui/resources/cr_elements/policy:cr_policy_network_behavior",
"//ui/webui/resources/js:assert",
"//ui/webui/resources/js:i18n_behavior",
]
externs_list = [
"$externs_path/chrome_send.js",
"$externs_path/networking_private.js",
]
extra_sources = [ "$interfaces_path/networking_private_interface.js" ]
}
# Copyright 2018 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.
{
'targets': [
{
'target_name': 'internet_config_dialog',
'dependencies': [
'<(DEPTH)/ui/webui/resources/cr_components/chromeos/network/compiled_resources2.gyp:network_config',
'<(DEPTH)/ui/webui/resources/cr_elements/chromeos/network/compiled_resources2.gyp:cr_onc_types',
'<(DEPTH)/ui/webui/resources/cr_elements/cr_dialog/compiled_resources2.gyp:cr_dialog',
'<(DEPTH)/ui/webui/resources/cr_elements/policy/compiled_resources2.gyp:cr_policy_network_behavior',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:assert',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:i18n_behavior',
'<(EXTERNS_GYP):chrome_send',
'<(EXTERNS_GYP):networking_private',
'<(INTERFACES_GYP):networking_private_interface',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
],
}
# Copyright 2018 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("../../optimize_webui.gni")
import("//third_party/closure_compiler/compile_js.gni")
optimize_webui("build") {
host = "internet_detail_dialog"
......@@ -10,3 +15,23 @@ optimize_webui("build") {
deps = []
}
js_type_check("closure_compile") {
deps = [
":internet_detail_dialog",
]
}
js_library("internet_detail_dialog") {
deps = [
"//ui/webui/resources/cr_elements/chromeos/network:cr_onc_types",
"//ui/webui/resources/cr_elements/policy:cr_policy_network_behavior",
"//ui/webui/resources/js:assert",
"//ui/webui/resources/js:i18n_behavior",
]
externs_list = [
"$externs_path/chrome_send.js",
"$externs_path/networking_private.js",
]
extra_sources = [ "$interfaces_path/networking_private_interface.js" ]
}
# Copyright 2018 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.
{
'targets': [
{
'target_name': 'internet_detail_dialog',
'dependencies': [
'<(DEPTH)/ui/webui/resources/cr_elements/chromeos/network/compiled_resources2.gyp:cr_onc_types',
'<(DEPTH)/ui/webui/resources/cr_elements/policy/compiled_resources2.gyp:cr_policy_network_behavior',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:assert',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:i18n_behavior',
'<(EXTERNS_GYP):chrome_send',
'<(EXTERNS_GYP):networking_private',
'<(INTERFACES_GYP):networking_private_interface',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
],
}
# Copyright 2018 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("//third_party/closure_compiler/compile_js.gni")
js_type_check("closure_compile") {
deps = [
":offline_ad_login",
":oobe_change_picture",
":oobe_select",
]
}
js_library("oobe_select") {
}
js_library("offline_ad_login") {
deps = [
":oobe_select",
"//ui/webui/resources/js:load_time_data",
]
}
js_library("oobe_change_picture") {
deps = [
"//ui/webui/resources/cr_elements/chromeos/cr_picture:cr_picture_list",
"//ui/webui/resources/cr_elements/chromeos/cr_picture:cr_picture_pane",
"//ui/webui/resources/cr_elements/chromeos/cr_picture:cr_picture_types",
"//ui/webui/resources/js:assert",
"//ui/webui/resources/js:i18n_behavior",
"//ui/webui/resources/js:load_time_data",
"//ui/webui/resources/js:util",
]
}
# Copyright 2016 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.
{
'targets': [
{
'target_name': 'oobe_select',
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'offline_ad_login',
'dependencies': [
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:load_time_data',
':oobe_select',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'oobe_change_picture',
'dependencies': [
'<(DEPTH)/ui/webui/resources/cr_elements/chromeos/cr_picture/compiled_resources2.gyp:cr_picture_list',
'<(DEPTH)/ui/webui/resources/cr_elements/chromeos/cr_picture/compiled_resources2.gyp:cr_picture_pane',
'<(DEPTH)/ui/webui/resources/cr_elements/chromeos/cr_picture/compiled_resources2.gyp:cr_picture_types',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:assert',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:i18n_behavior',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:load_time_data',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:util',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
],
}
# Copyright 2018 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("//third_party/closure_compiler/compile_js.gni")
js_type_check("closure_compile") {
deps = [
":button_bar",
":fake_mojo_service",
":multidevice_setup",
":multidevice_setup_dialog",
":setup_failed_page",
":setup_succeeded_page",
":start_setup_page",
":ui_mode",
":ui_page_container_behavior",
]
}
js_library("button_bar") {
}
js_library("fake_mojo_service") {
deps = [
"//ui/webui/resources/js:cr",
]
}
js_library("multidevice_setup") {
deps = [
":button_bar",
":fake_mojo_service",
":setup_failed_page",
":setup_succeeded_page",
":start_setup_page",
":ui_mode",
"//ui/webui/resources/js:cr",
]
}
js_library("multidevice_setup_dialog") {
deps = [
":multidevice_setup",
":ui_mode",
"//ui/webui/resources/js:util",
]
}
js_library("setup_failed_page") {
deps = [
":ui_page_container_behavior",
]
}
js_library("setup_succeeded_page") {
deps = [
":ui_page_container_behavior",
]
}
js_library("start_setup_page") {
deps = [
":ui_page_container_behavior",
]
}
js_library("ui_mode") {
deps = [
"//ui/webui/resources/js:cr",
]
}
js_library("ui_page_container_behavior") {
deps = [
"//ui/webui/resources/js:cr",
"//ui/webui/resources/js:i18n_behavior",
]
}
#Copyright 2018 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.
{
'targets' : [
{
'target_name' : 'button_bar',
'dependencies' : [],
'includes' :
['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name' : 'fake_mojo_service',
'dependencies' : [
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:cr',
],
'includes' :
['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name' : 'multidevice_setup',
'dependencies' : [
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:cr',
'button_bar',
'fake_mojo_service',
'start_setup_page',
'setup_succeeded_page',
'setup_failed_page',
'ui_mode',
],
'includes' :
['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name' : 'multidevice_setup_dialog',
'dependencies' : [
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:util',
'multidevice_setup',
'ui_mode',
],
'includes' :
['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name' : 'setup_failed_page',
'dependencies' : [
'ui_page_container_behavior',
],
'includes' :
['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name' : 'setup_succeeded_page',
'dependencies' : [
'ui_page_container_behavior',
],
'includes' :
['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name' : 'start_setup_page',
'dependencies' : [
'ui_page_container_behavior',
],
'includes' :
['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name' : 'ui_mode',
'dependencies' : [
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:cr',
],
'includes' :
['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name' : 'ui_page_container_behavior',
'dependencies' : [
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:cr',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:i18n_behavior',
],
'includes' :
['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
],
}
# Copyright 2018 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("//third_party/closure_compiler/compile_js.gni")
js_type_check("closure_compile") {
deps = [
":network_ui",
]
}
js_library("network_ui") {
deps = [
"//ui/webui/resources/cr_elements/chromeos/network:cr_network_icon_externs",
"//ui/webui/resources/cr_elements/chromeos/network:cr_onc_types",
"//ui/webui/resources/js:load_time_data",
"//ui/webui/resources/js:util",
]
externs_list = [ "$externs_path/networking_private.js" ]
}
# Copyright 2016 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.
{
'targets': [
{
'target_name': 'network_ui',
'dependencies': [
'<(DEPTH)/ui/webui/resources/cr_elements/chromeos/network/compiled_resources2.gyp:cr_network_icon_externs',
'<(DEPTH)/ui/webui/resources/cr_elements/chromeos/network/compiled_resources2.gyp:cr_onc_types',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:load_time_data',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:util',
'<(EXTERNS_GYP):networking_private',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
],
}
......@@ -6,12 +6,13 @@ import("//build/config/features.gni")
import("//testing/test.gni")
import("//chrome/test/base/js2gtest.gni")
import("//chrome/browser/resources/chromeos/chromevox/run_jsbundler.gni")
import("//third_party/closure_compiler/compile_js.gni")
assert(is_chromeos)
select_to_speak_out_dir = "$root_out_dir/resources/chromeos/select_to_speak"
group("select_to_speak") {
group("build") {
deps = [
":select_to_speak_copied_files",
":select_to_speak_guest_manifest",
......@@ -160,3 +161,121 @@ js2gtest("select_to_speak_extjs_tests") {
]
defines = [ "HAS_OUT_OF_PROC_TEST_RUNNER" ]
}
js_type_check("closure_compile") {
deps = [
":../chromevox/cvox2/background/automation_predicate",
":../chromevox/cvox2/background/automation_util",
":../chromevox/cvox2/background/constants",
":../chromevox/cvox2/background/tree_walker",
":closure_shim",
":node_utils",
":paragraph_utils",
":rect_utils",
":select_to_speak",
":select_to_speak_options",
":word_utils",
]
}
js_library("select_to_speak") {
deps = [
":../chromevox/cvox2/background/automation_util",
":../chromevox/cvox2/background/constants",
":node_utils",
":paragraph_utils",
":rect_utils",
":word_utils",
]
externs_list = [
"$externs_path/accessibility_private.js",
"$externs_path/automation.js",
"$externs_path/chrome_extensions.js",
"$externs_path/clipboard.js",
"$externs_path/command_line_private.js",
"$externs_path/metrics_private.js",
"externs.js",
]
}
js_library("select_to_speak_options") {
externs_list = [
"externs.js",
"$externs_path/accessibility_private.js",
"$externs_path/automation.js",
"$externs_path/chrome_extensions.js",
"$externs_path/metrics_private.js",
]
}
js_library("node_utils") {
deps = [
":paragraph_utils",
":rect_utils",
]
externs_list = [
"externs.js",
"$externs_path/automation.js",
]
}
js_library("word_utils") {
deps = [
":paragraph_utils",
]
externs_list = [
"externs.js",
"$externs_path/automation.js",
]
}
js_library("paragraph_utils") {
externs_list = [
"externs.js",
"$externs_path/accessibility_private.js",
"$externs_path/automation.js",
"$externs_path/chrome_extensions.js",
]
}
js_library("rect_utils") {
}
js_library("../chromevox/cvox2/background/automation_util") {
deps = [
":../chromevox/cvox2/background/automation_predicate",
":../chromevox/cvox2/background/constants",
":../chromevox/cvox2/background/tree_walker",
]
externs_list = [
"$externs_path/automation.js",
"$externs_path/chrome_extensions.js",
]
}
js_library("../chromevox/cvox2/background/tree_walker") {
deps = [
":../chromevox/cvox2/background/automation_predicate",
":../chromevox/cvox2/background/constants",
]
externs_list = [
"$externs_path/automation.js",
"$externs_path/chrome_extensions.js",
]
}
js_library("../chromevox/cvox2/background/automation_predicate") {
deps = [
":../chromevox/cvox2/background/constants",
]
externs_list = [
"$externs_path/automation.js",
"$externs_path/chrome_extensions.js",
]
}
js_library("../chromevox/cvox2/background/constants") {
}
js_library("closure_shim") {
}
# Copyright 2016 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.
{
'targets': [
{
'target_name': 'select_to_speak',
'dependencies': [
'../chromevox/cvox2/background/constants',
'../chromevox/cvox2/background/automation_util',
'externs',
'rect_utils',
'paragraph_utils',
'word_utils',
'node_utils',
'<(EXTERNS_GYP):accessibility_private',
'<(EXTERNS_GYP):automation',
'<(EXTERNS_GYP):chrome_extensions',
'<(EXTERNS_GYP):clipboard',
'<(EXTERNS_GYP):command_line_private',
'<(EXTERNS_GYP):metrics_private',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'select_to_speak_options',
'dependencies': [
'externs',
'<(EXTERNS_GYP):accessibility_private',
'<(EXTERNS_GYP):automation',
'<(EXTERNS_GYP):chrome_extensions',
'<(EXTERNS_GYP):metrics_private',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'externs',
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'node_utils',
'dependencies': [
'externs',
'rect_utils',
'paragraph_utils',
'<(EXTERNS_GYP):automation',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'word_utils',
'dependencies': [
'externs',
'paragraph_utils',
'<(EXTERNS_GYP):automation',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'paragraph_utils',
'dependencies': [
'externs',
'<(EXTERNS_GYP):accessibility_private',
'<(EXTERNS_GYP):automation',
'<(EXTERNS_GYP):chrome_extensions',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'rect_utils',
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': '../chromevox/cvox2/background/automation_util',
'dependencies': [
'../chromevox/cvox2/background/automation_predicate',
'../chromevox/cvox2/background/tree_walker',
'../chromevox/cvox2/background/constants',
'<(EXTERNS_GYP):automation',
'<(EXTERNS_GYP):chrome_extensions',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': '../chromevox/cvox2/background/tree_walker',
'dependencies': [
'../chromevox/cvox2/background/automation_predicate',
'../chromevox/cvox2/background/constants',
'<(EXTERNS_GYP):automation',
'<(EXTERNS_GYP):chrome_extensions',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': '../chromevox/cvox2/background/automation_predicate',
'dependencies': [
'../chromevox/cvox2/background/constants',
'<(EXTERNS_GYP):automation',
'<(EXTERNS_GYP):chrome_extensions',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': '../chromevox/cvox2/background/constants',
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'closure_shim',
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
],
}
......@@ -6,12 +6,13 @@ import("//build/config/features.gni")
import("//testing/test.gni")
import("//chrome/test/base/js2gtest.gni")
import("//chrome/browser/resources/chromeos/chromevox/run_jsbundler.gni")
import("//third_party/closure_compiler/compile_js.gni")
assert(is_chromeos)
switch_access_dir = "$root_out_dir/resources/chromeos/switch_access"
group("switch_access") {
group("build") {
deps = [
":switch_access_copied_files",
":switch_access_guest_manifest",
......@@ -107,3 +108,97 @@ manifest("switch_access_guest_manifest") {
output_file = "$switch_access_dir/manifest_guest.json"
is_guest_manifest = true
}
js_type_check("closure_compile") {
deps = [
":auto_scan_manager",
":automation_manager",
":automation_predicate",
":background",
":commands",
":keyboard_handler",
":options",
":prefs",
# ":switch_access",
":switch_access_interface",
":tree_walker",
]
}
js_library("auto_scan_manager") {
deps = [
":switch_access_interface",
]
}
js_library("automation_manager") {
deps = [
":automation_predicate",
":tree_walker",
]
externs_list = [
"$externs_path/accessibility_private.js",
"$externs_path/automation.js",
]
}
js_library("automation_predicate") {
externs_list = [ "$externs_path/automation.js" ]
}
js_library("background") {
deps = [
":switch_access",
]
externs_list = [ "$externs_path/chrome_extensions.js" ]
}
js_library("commands") {
deps = [
":switch_access_interface",
]
}
js_library("keyboard_handler") {
deps = [
":switch_access_interface",
]
externs_list = [ "$externs_path/accessibility_private.js" ]
}
js_library("options") {
deps = [
":background",
":switch_access",
]
externs_list = [ "$externs_path/chrome_extensions.js" ]
}
js_library("prefs") {
deps = [
":switch_access_interface",
]
externs_list = [ "$externs_path/chrome_extensions.js" ]
}
js_library("switch_access") {
deps = [
":auto_scan_manager",
":automation_manager",
":commands",
":keyboard_handler",
":prefs",
]
externs_list = [
"$externs_path/automation.js",
"$externs_path/chrome_extensions.js",
]
}
js_library("switch_access_interface") {
}
js_library("tree_walker") {
externs_list = [ "$externs_path/automation.js" ]
}
# Copyright 2017 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.
{
'targets': [
{
'target_name': 'auto_scan_manager',
'dependencies': [
'switch_access_interface',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'automation_manager',
'dependencies': [
'<(EXTERNS_GYP):accessibility_private',
'<(EXTERNS_GYP):automation',
'automation_predicate',
'tree_walker',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'automation_predicate',
'dependencies': [
'<(EXTERNS_GYP):automation',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'background',
'dependencies': [
'<(EXTERNS_GYP):chrome_extensions',
'switch_access',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'commands',
'dependencies': [
'switch_access_interface',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'keyboard_handler',
'dependencies': [
'<(EXTERNS_GYP):accessibility_private',
'switch_access_interface',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'options',
'dependencies': [
'<(EXTERNS_GYP):chrome_extensions',
'switch_access',
'background',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'prefs',
'dependencies': [
'<(EXTERNS_GYP):chrome_extensions',
'switch_access_interface',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'switch_access',
'dependencies': [
'<(EXTERNS_GYP):automation',
'<(EXTERNS_GYP):chrome_extensions',
'auto_scan_manager',
'automation_manager',
'commands',
'keyboard_handler',
'prefs',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'switch_access_interface',
'dependencies': [],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'tree_walker',
'dependencies': [
'<(EXTERNS_GYP):automation',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
}
],
}
# Copyright 2018 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("//third_party/closure_compiler/compile_js.gni")
js_type_check("closure_compile") {
deps = [
":constants",
":index",
":types",
]
}
js_library("index") {
deps = [
":constants",
":types",
"line_chart:line_chart",
"//ui/webui/resources/js:cr",
]
externs_list = [ "externs.js" ]
}
js_library("constants") {
deps = [
"//ui/webui/resources/js:cr",
]
}
js_library("types") {
deps = [
"line_chart:data_series",
]
}
# Copyright 2017 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.
{
'targets': [
{
'target_name': 'index',
'dependencies': [
'constants',
'externs',
'types',
'line_chart/compiled_resources2.gyp:*',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:cr',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'constants',
'dependencies': [
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:cr',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'externs',
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'types',
'dependencies': [
'line_chart/compiled_resources2.gyp:data_series',
],
'includes': ['../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
],
}
# Copyright 2018 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("//third_party/closure_compiler/compile_js.gni")
js_type_check("closure_compile") {
deps = [
":constants",
":data_series",
":line_chart",
":menu",
":scrollbar",
":sub_chart",
":unit_label",
]
}
js_library("line_chart") {
deps = [
":constants",
":data_series",
":menu",
":scrollbar",
":sub_chart",
"//ui/webui/resources/js:util",
]
}
js_library("sub_chart") {
deps = [
":constants",
":data_series",
":unit_label",
]
}
js_library("scrollbar") {
deps = [
":constants",
"//ui/webui/resources/js:util",
]
}
js_library("unit_label") {
deps = [
":constants",
]
}
js_library("menu") {
deps = [
":constants",
":data_series",
"//ui/webui/resources/js:util",
]
}
js_library("data_series") {
deps = [
":constants",
]
}
js_library("constants") {
}
# Copyright 2017 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.
{
'targets': [
{
'target_name': 'line_chart',
'dependencies': [
'sub_chart',
'data_series',
'scrollbar',
'menu',
'constants',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:util',
],
'includes': ['../../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'sub_chart',
'dependencies': [
'unit_label',
'data_series',
'constants',
],
'includes': ['../../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'scrollbar',
'dependencies': [
'constants',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:util',
],
'includes': ['../../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'unit_label',
'dependencies': [
'constants',
],
'includes': ['../../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'menu',
'dependencies': [
'constants',
'data_series',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:util',
],
'includes': ['../../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'data_series',
'dependencies': [
'constants',
],
'includes': ['../../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
{
'target_name': 'constants',
'includes': ['../../../../../../third_party/closure_compiler/compile_js2.gypi'],
},
],
}
......@@ -14,14 +14,6 @@
'target_name': 'compiled_resources2',
'type': 'none',
'dependencies': [
'<(DEPTH)/chrome/browser/resources/chromeos/braille_ime/compiled_resources2.gyp:*',
'<(DEPTH)/chrome/browser/resources/chromeos/compiled_resources2.gyp:*',
'<(DEPTH)/chrome/browser/resources/chromeos/login/compiled_resources2.gyp:*',
'<(DEPTH)/chrome/browser/resources/chromeos/multidevice_setup/compiled_resources2.gyp:*',
'<(DEPTH)/chrome/browser/resources/chromeos/network_ui/compiled_resources2.gyp:*',
'<(DEPTH)/chrome/browser/resources/chromeos/select_to_speak/compiled_resources2.gyp:*',
'<(DEPTH)/chrome/browser/resources/chromeos/switch_access/compiled_resources2.gyp:*',
'<(DEPTH)/chrome/browser/resources/chromeos/sys_internals/compiled_resources2.gyp:*',
'<(DEPTH)/ui/webui/resources/cr_components/compiled_resources2.gyp:*',
'<(DEPTH)/ui/webui/resources/cr_elements/compiled_resources2.gyp:*',
'<(DEPTH)/ui/webui/resources/js/compiled_resources2.gyp:*',
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment