Commit Graph

58 Commits

Author SHA1 Message Date
Florian Quèze
f1a55f73f8 Bug 1440284 - change this.EXPORTED_SYMBOLS back to var EXPORTED_SYMBOLS in JS modules, r=mccr8. 2018-02-23 20:50:01 +01:00
Andrew McCreight
272cee1e65 Bug 1432992, part 1 - Remove definitions of Ci, Cr, Cc, and Cu. r=florian
This patch was autogenerated by my decomponents.py

It covers almost every file with the extension js, jsm, html, py,
xhtml, or xul.

It removes blank lines after removed lines, when the removed lines are
preceded by either blank lines or the start of a new block. The "start
of a new block" is defined fairly hackily: either the line starts with
//, ends with */, ends with {, <![CDATA[, """ or '''. The first two
cover comments, the third one covers JS, the fourth covers JS embedded
in XUL, and the final two cover JS embedded in Python. This also
applies if the removed line was the first line of the file.

It covers the pattern matching cases like "var {classes: Cc,
interfaces: Ci, utils: Cu, results: Cr} = Components;". It'll remove
the entire thing if they are all either Ci, Cr, Cc or Cu, or it will
remove the appropriate ones and leave the residue behind. If there's
only one behind, then it will turn it into a normal, non-pattern
matching variable definition. (For instance, "const { classes: Cc,
Constructor: CC, interfaces: Ci, utils: Cu } = Components" becomes
"const CC = Components.Constructor".)

MozReview-Commit-ID: DeSHcClQ7cG
2018-02-06 09:36:57 -08:00
Florian Quèze
c5f15a4700 Bug 1339461 - script-generated patch to convert foo.indexOf(...) == -1 to foo.includes(), r=Mossop. 2018-02-01 20:45:22 +01:00
Kris Maglione
0bb74efdf1 Bug 1431533: Part 5a - Auto-rewrite code to use ChromeUtils import methods. r=florian
This was done using the following script:
37e3803c7a/processors/chromeutils-import.jsm

MozReview-Commit-ID: 1Nc3XDu0wGl
2018-01-29 15:20:18 -08:00
Cosmin Sabou
f09d6d985d Backed out 3 changesets (bug 1431533) for Android mochitest failures on testEventDispatcher on a CLOSED TREE
Backed out changeset a1eca62826a1 (bug 1431533)
Backed out changeset 34c999fa006b (bug 1431533)
Backed out changeset e2674287e57f (bug 1431533)
2018-01-30 07:17:48 +02:00
Kris Maglione
fd67f090b2 Bug 1431533: Part 5a - Auto-rewrite code to use ChromeUtils import methods. r=florian
This was done using the following script:
37e3803c7a/processors/chromeutils-import.jsm

MozReview-Commit-ID: 1Nc3XDu0wGl
2018-01-29 15:20:18 -08:00
Brindusan Cristian
483ba301cb Backed out 2 changesets (bug 1431533) for ESlint failures on a CLOSED TREE
Backed out changeset 6e56f4c8843e (bug 1431533)
Backed out changeset 12fc4dee861c (bug 1431533)
2018-01-30 02:32:43 +02:00
Kris Maglione
683a97d172 Bug 1431533: Part 5a - Auto-rewrite code to use ChromeUtils import methods. r=florian
This was done using the following script:
37e3803c7a/processors/chromeutils-import.jsm

MozReview-Commit-ID: 1Nc3XDu0wGl
2018-01-29 15:20:18 -08:00
Aditya Bharti
2d986b1f27 Bug 1408429 - Fix Translation Telemetry shouldn't check toolkit.telemetry.enabled pref. r=chutten
Removed the definition and all uses of _canRecord from Translation.jsm.
Test file browser_translation_telemetry.js did not need to be changed
as it was taken care of in bug 1406391.
2017-11-16 23:29:46 +05:30
Florian Quèze
b622c2b081 Bug 1368456 - Remove imports of Promise.jsm from Firefox, r=mconley. 2017-06-23 11:25:18 +02:00
Florian Quèze
ff53eb9a63 Bug 1353542 - massive script-generated patch converting Task.async and Task.spawn calls, and generators clearly identifiable as tasks, rs=Mossop. 2017-05-12 14:42:39 +02:00
Jared Wein
5a181760cc Bug 1348068 - Enable the key-spacing rule for eslint and fix the related issues. r=standard8
Running eslint with --fix didn't fix many of the issues. The majority here had to be fixed by hand but a significant majority of the issues were related to a few files that I was able to use find-and-replace with. I regret not making this in to separate commits of the hand-fixes and the fixes from --fix but I don't recall --fix fixing any of the issues.

MozReview-Commit-ID: ANyg2qfo3Qx
2017-03-21 14:29:43 -04:00
Zibi Braniecki
e1617486a8 Bug 1347314 - Migrate calls to ChromeRegistry::GetSelectedLocale to use LocaleService::GetAppLocale. r=jfkthame,Pike
In cases, where the caller is looking for the locale to be used for JS Intl API,
we can now replace it with `undefined` which causes JS Intl API to use the default
locale which since bug 1346674 is resolved to the app locale.

This allows us to remove a lot of calls for the app locale.

The remaining ones are split between `AsBCP47` and `AsLangTag`.
Here, the `AsLangTag` is used, as described in the API docs, for cases where
the language string is used for localization purposes, such as language negotaition
matching to our language resources etc.
`AsBCP47` is used when the returned value is handed over to ICU API.

MozReview-Commit-ID: DzmFEUvMq3N
2017-03-14 16:09:54 -07:00
Sebastian Hengst
1f6ea2382a Backed out changeset cc308a73ad05 (bug 1347314) for eslint failure in test_device.html. r=backout 2017-03-22 18:20:26 +01:00
Zibi Braniecki
a56e4c7360 Bug 1347314 - Migrate calls to ChromeRegistry::GetSelectedLocale to use LocaleService::GetAppLocale. r=jfkthame,Pike
In cases, where the caller is looking for the locale to be used for JS Intl API,
we can now replace it with `undefined` which causes JS Intl API to use the default
locale which since bug 1346674 is resolved to the app locale.

This allows us to remove a lot of calls for the app locale.

The remaining ones are split between `AsBCP47` and `AsLangTag`.
Here, the `AsLangTag` is used, as described in the API docs, for cases where
the language string is used for localization purposes, such as language negotaition
matching to our language resources etc.
`AsBCP47` is used when the returned value is handed over to ICU API.

MozReview-Commit-ID: DzmFEUvMq3N
2017-03-14 16:09:54 -07:00
Jared Wein
242ab87626 Bug 1326511 - Enable brace-style and no-multi-spaces eslint rules for toolkit. r=MattN
MozReview-Commit-ID: FuVu8skcqOe
2016-12-30 21:47:25 -05:00
Jared Wein
e3149c378f Bug 1325464 - Enable object-shorthand rule and run 'mach eslint --fix' with the rule enabled. r=MattN
MozReview-Commit-ID: 7E7LPorrEje
2016-12-29 18:34:54 -05:00
Wes Kocher
2d7553dcfd Backed out 3 changesets (bug 1325464) for xpcshell failures a=backout
Backed out changeset 562ddc32cc21 (bug 1325464)
Backed out changeset cd10db6087dd (bug 1325464)
Backed out changeset 4079437c4648 (bug 1325464)
2016-12-29 14:05:44 -08:00
Jared Wein
34e228f767 Bug 1325464 - Enable object-shorthand rule and run 'mach eslint --fix' with the rule enabled. r=MattN
MozReview-Commit-ID: 8WoGr8i6oCR
2016-12-29 15:20:47 -05:00
Jared Wein
ef8b1e86ca Bug 1316870 - Enable no-shadow eslint rule for browser/. r=mossop 2016-11-15 22:58:30 -05:00
Dave Townsend
4e295aa48d Bug 1316882: Turn on space-before-function-paren eslint rule (browser). r=jaws
MozReview-Commit-ID: 2ZvTiZDHchz
2016-11-11 08:10:51 -08:00
Tooru Fujisawa
a2d438cd88 Bug 1207491 - Part 20: Remove use of expression closure from browser/components/translation/. r=Gijs 2015-09-23 18:36:24 +09:00
Iaroslav Sheptykin
d3f1c02874 Bug 1121006 - Migrate translation component from FHR to telemetry histograms. r=gfritzsche 2015-08-21 22:55:30 +02:00
Iaroslav (yarik) Sheptykin
f8cbf6904e Bug 1191306 - Replacing .includes with indexOf to avoid test failures on Aurora. r=felipe 2015-08-05 16:47:22 +02:00
Iaroslav Sheptykin
34d74cad80 Bug 1174468 - Show Yandex.Translate attribution when Yandex engine is selected. r=felipc 2015-07-20 06:54:00 -04:00
Florian Quèze
7093afbcd9 Bug 1072742 - Add more language targets for translation, r=felipe. 2014-10-06 15:22:45 +02:00
Florian Quèze
c31e873db9 Bug 1046142 - Empty language to translate to drop down on localized builds, r=gavin. 2014-08-01 15:18:46 +02:00
Florian Quèze
3db1e7cbb7 Bug 1027024 - Never translate 'language' disappears when close/open translation infobar using a expired key - follow-up, r=mikedeboer. 2014-07-21 12:24:43 +02:00
Steven MacLeod
59239aa9d8 Bug 1035337 - Record when the infobar is hidden due to "Never translate this language/site". r=felipe 2014-07-10 22:13:09 -04:00
Steven MacLeod
4f5a06ad6d Bug 1035337 - Introduce API to record when the infobar is hidden due to "Never translate this language/site". r=felipe 2014-07-10 18:31:56 -04:00
Asaf Romano
ec3822459a Bug 977770 - Count the times users manually adjust the offered translation pair. r=felipe. 2014-06-24 16:53:30 +03:00
Asaf Romano
522fb57bdb Bug 973294 - Count the number of times 'Show Original' is used. r=felipe. 2014-06-24 11:41:52 +03:00
Asaf Romano
953a16f119 Bug 977774 - Count the number of times a user opts out of Instant Translation. r=felipe. 2014-06-24 11:40:24 +03:00
Carsten "Tomcat" Book
5588d6e403 Backed out changeset 5e0288a4e398 (bug 977774) for bc1 test failures 2014-06-24 09:13:47 +02:00
Carsten "Tomcat" Book
7790fc1ed3 Backed out changeset 895eeb7bddb8 (bug 973294) for bc1 test failures 2014-06-24 09:13:34 +02:00
Asaf Romano
c2fa9d93c5 Bug 973294 - Firefox counts the number of times that users pick 'Show Original'. r=felipe. 2014-06-24 08:36:56 +03:00
Asaf Romano
77531db424 Bug 977774 - Count the number of times a user opts out of Instant Translation. r=felipe. 2014-06-24 08:30:47 +03:00
Asaf Romano
c4bdb450fc Bug 977774 - Metric for tracking opts out of Instant Translation. r=felipe. 2014-06-22 12:23:40 +03:00
Florian Quèze
86c0cb8003 Bug 1022856 - Implement translator provider attribution. r=felipe
Parts of the patch written by Felipe, with r=florian
2014-06-20 15:50:41 -03:00
Wes Kocher
598abac968 Merge inbound to m-c a=merge 2014-06-19 18:07:43 -07:00
Florian Quèze
e51aa2399c Bug 1022640 - the Translation UI disappears when tearing off a tab, r=felipe. 2014-06-19 19:40:24 +02:00
Felipe Gomes
26b4e57b08 Bug 1024757 - Translation FHR should report missed opportunities due to the detected language not being part of the list of supported languages. r=mdeboer 2014-06-19 13:42:29 -03:00
Felipe Gomes
da7f504200 Bug 1022413 - Update list of languages supported by automatic translation. r=MattN 2014-06-18 21:07:12 -03:00
Florian Quèze
ae85baec9c Bug 1012535 - Handle translation service unavailable errors, r=felipe. 2014-06-16 17:50:08 +02:00
Tim Taubert
ec6220ff71 Bug 973292 - Record the number of characters that are translated with FHR r=felipe 2014-06-11 15:57:52 +02:00
Florian Quèze
19e6c7f17a Bug 1017560 - Choosing the same language will modify the state of Show Translation button, r=felipe. 2014-06-11 12:15:36 +02:00
Florian Quèze
910b104d7d Bug 1015527 - Back/Forward navigation shouldn't break the Translation UI, r=felipe. 2014-06-09 16:50:58 +02:00
Mike de Boer
28bee797d4 Bug 1015525: changes to translation prefs are now recorded by FHR. r=rnewman 2014-06-04 15:32:08 +02:00
Steven MacLeod
2079b688cf Bug 978158 - Setup FHR provider for Translation project r=felipe,rnewman 2014-06-03 18:08:35 +02:00
Asaf Romano
6fc2615562 Bug 988275 - Choosing the same language in Translation Infobar will attempt to translate. r=florian 2014-05-26 17:03:13 +03:00