From d8bbc7858622b6d9c278469aab701ca0b609cddf Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 15 May 2024 05:35:49 +0200 Subject: Merging upstream version 126.0. Signed-off-by: Daniel Baumann --- tools/tryselect/selectors/chooser/app.py | 17 +++++++++++++++++ tools/tryselect/selectors/chooser/static/filter.js | 6 +++--- tools/tryselect/selectors/chooser/static/select.js | 2 +- 3 files changed, 21 insertions(+), 4 deletions(-) (limited to 'tools/tryselect/selectors/chooser') diff --git a/tools/tryselect/selectors/chooser/app.py b/tools/tryselect/selectors/chooser/app.py index 99d63cd37f..2e9e2d5ab0 100644 --- a/tools/tryselect/selectors/chooser/app.py +++ b/tools/tryselect/selectors/chooser/app.py @@ -106,6 +106,23 @@ class Test(Section): return task.attributes["unittest_suite"] not in ("raptor", "talos") +@register_section +class Android(Section): + name = "android" + kind = ( + "build-apk,build-bundle,build-components,test-apk,test-components,ui-test-apk" + ) + title = "Firefox for Android" + attrs = ["kind", "build-type", "component", "shipping-product"] + + def labelfn(self, task): + if task["kind"] in ("build-components", "test-components"): + label = "{}-{}".format(task["kind"], task.get("component")) + else: + label = "{}-{}".format(task["kind"], task.get("build-type")) + return label + + @register_section class Perf(Section): name = "perf" diff --git a/tools/tryselect/selectors/chooser/static/filter.js b/tools/tryselect/selectors/chooser/static/filter.js index 2d8731e61f..683ced8953 100644 --- a/tools/tryselect/selectors/chooser/static/filter.js +++ b/tools/tryselect/selectors/chooser/static/filter.js @@ -10,7 +10,7 @@ const pluralize = (count, noun, suffix = "s") => var selected = []; var updateLabels = () => { - $(".tab-pane.active > .filter-label").each(function (index) { + $(".tab-pane.active > .filter-label").each(function () { let box = $("#" + this.htmlFor)[0]; let method = box.checked ? "add" : "remove"; $(this)[method + "Class"]("is-checked"); @@ -21,7 +21,7 @@ var apply = () => { let filters = {}; let kinds = []; - $(".filter:checked").each(function (index) { + $(".filter:checked").each(function () { for (let kind of this.name.split(",")) { if (!kinds.includes(kind)) { kinds.push(kind); @@ -76,7 +76,7 @@ var apply = () => { var applyChunks = () => { // For tasks that have a chunk filter applied, we handle that here. let filters = {}; - $(".filter:text").each(function (index) { + $(".filter:text").each(function () { let value = $(this).val(); if (value === "") { return; diff --git a/tools/tryselect/selectors/chooser/static/select.js b/tools/tryselect/selectors/chooser/static/select.js index 8a315c0a52..e90744a09a 100644 --- a/tools/tryselect/selectors/chooser/static/select.js +++ b/tools/tryselect/selectors/chooser/static/select.js @@ -39,7 +39,7 @@ labels.click(function (e) { function selectAll(btn) { let checked = !!btn.value; - $("div.active label.filter-label").each(function (index) { + $("div.active label.filter-label").each(function () { $(this).find("input:checkbox")[0].checked = checked; }); apply(); -- cgit v1.2.3