Commit Graph

183 Commits

Author SHA1 Message Date
Myk Melez
25349d2601 Bug 1518283 - prohibit blank lines at the beginning and end of blocks (eslint padded-blocks) r=mossop,Standard8
Differential Revision: https://phabricator.services.mozilla.com/D17526

--HG--
extra : moz-landing-system : lando
2019-01-30 17:26:25 +00:00
Kris Maglione
e930b89c34 Bug 1514594: Part 3 - Change ChromeUtils.import API.
***
Bug 1514594: Part 3a - Change ChromeUtils.import to return an exports object; not pollute global. r=mccr8

This changes the behavior of ChromeUtils.import() to return an exports object,
rather than a module global, in all cases except when `null` is passed as a
second argument, and changes the default behavior not to pollute the global
scope with the module's exports. Thus, the following code written for the old
model:

  ChromeUtils.import("resource://gre/modules/Services.jsm");

is approximately the same as the following, in the new model:

  var {Services} = ChromeUtils.import("resource://gre/modules/Services.jsm");

Since the two behaviors are mutually incompatible, this patch will land with a
scripted rewrite to update all existing callers to use the new model rather
than the old.
***
Bug 1514594: Part 3b - Mass rewrite all JS code to use the new ChromeUtils.import API. rs=Gijs

This was done using the followng script:

https://bitbucket.org/kmaglione/m-c-rewrites/src/tip/processors/cu-import-exports.jsm
***
Bug 1514594: Part 3c - Update ESLint plugin for ChromeUtils.import API changes. r=Standard8

Differential Revision: https://phabricator.services.mozilla.com/D16747
***
Bug 1514594: Part 3d - Remove/fix hundreds of duplicate imports from sync tests. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16748
***
Bug 1514594: Part 3e - Remove no-op ChromeUtils.import() calls. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16749
***
Bug 1514594: Part 3f.1 - Cleanup various test corner cases after mass rewrite. r=Gijs
***
Bug 1514594: Part 3f.2 - Cleanup various non-test corner cases after mass rewrite. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16750

--HG--
extra : rebase_source : 359574ee3064c90f33bf36c2ebe3159a24cc8895
extra : histedit_source : b93c8f42808b1599f9122d7842d2c0b3e656a594%2C64a3a4e3359dc889e2ab2b49461bab9e27fc10a7
2019-01-17 10:18:31 -08:00
Emilio Cobos Álvarez
d2ed260822 Bug 1517241 - Rename nsIDocument to mozilla::dom::Document. r=smaug
Summary: Really sorry for the size of the patch. It's mostly automatic
s/nsIDocument/Document/ but I had to fix up in a bunch of places manually to
add the right namespacing and such.

Overall it's not a very interesting patch I think.

nsDocument.cpp turns into Document.cpp, nsIDocument.h into Document.h and
nsIDocumentInlines.h into DocumentInlines.h.

I also changed a bunch of nsCOMPtr usage to RefPtr, but not all of it.

While fixing up some of the bits I also removed some unneeded OwnerDoc() null
checks and such, but I didn't do anything riskier than that.
2019-01-03 17:48:33 +01:00
Emilio Cobos Álvarez
63814207cb Bug 1516853 - Merge nsIDocument and nsDocument. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D15498

--HG--
extra : moz-landing-system : lando
2018-12-31 14:10:19 +00:00
Emilio Cobos Álvarez
006a4ab94a Bug 1516366 - Move nsOnloadBlocker and nsDocumentOnStack to nsDocument.cpp, and shrink nsDocument.h to the minimmum. r=smaug
This needs to add a few of includes in other places which were relying on the
massive (now gone) list in nsDocument.h.

I also needed to move an AnimationTimeline destructor out of line because it
relied on dom::Animation being defined, yet Animation.h includes
AnimationTimeline.h, so include hell.

Differential Revision: https://phabricator.services.mozilla.com/D15366
2018-12-29 20:41:42 +01:00
Alex Kong
1a4b7d1b8a Bug 1508988 - Enable ESLint for dom/abort/, dom/asmjscache/, dom/battery/, dom/broadcastchannel/ and dom/console/ (manual changes). r=Standard8,nika
Differential Revision: https://phabricator.services.mozilla.com/D14132

--HG--
extra : moz-landing-system : lando
2018-12-19 22:39:34 +00:00
Alex Kong
a164593e05 Bug 1508988 - Enable ESLint for dom/abort/, dom/asmjscache/, dom/battery/, dom/broadcastchannel/ and dom/console/ (automatic changes). r=Standard8,nika
Differential Revision: https://phabricator.services.mozilla.com/D14131

--HG--
extra : moz-landing-system : lando
2018-12-19 22:38:44 +00:00
Sylvestre Ledru
265e672179 Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset

--HG--
extra : amend_source : 4d301d3b0b8711c4692392aa76088ba7fd7d1022
2018-11-30 11:46:48 +01:00
Karl Tomlinson
72e20a68c4 Bug 1476514 remove WorkleThread::Get() usage from Console r=baku
Depends on D13213

Differential Revision: https://phabricator.services.mozilla.com/D13214

--HG--
extra : moz-landing-system : lando
2018-11-28 17:31:20 +00:00
Karl Tomlinson
76f7458b87 bug 1476514 use a distinct method to send runnables from parent to worklet thread r=baku
and create the worklet thread on demand from there.

Differential Revision: https://phabricator.services.mozilla.com/D13213

--HG--
extra : moz-landing-system : lando
2018-11-28 23:47:01 +00:00
Karl Tomlinson
ffd18ba6eb Bug 1476514 dispatch ConsoleProfileWorkletRunnables to main thread rather than worklet thread r=baku
This is consistent with ConsoleCallDataWorkletRunnable queuing and enables
ConsoleProfileWorkletRunnable::RunOnMainThread() to run.

Depends on D13210

Differential Revision: https://phabricator.services.mozilla.com/D13211

--HG--
extra : moz-landing-system : lando
2018-11-28 17:23:35 +00:00
Karl Tomlinson
9db064fcec Bug 1476514 move TimeStampToDOMHighRes() from WorkletThread to WorkletGlobalScope r=baku
Differential Revision: https://phabricator.services.mozilla.com/D13210

--HG--
extra : moz-landing-system : lando
2018-11-28 17:09:24 +00:00
Andrea Marchesini
c0950f9d8a Bug 1480544 - Allow Console API to log messages on stdout, r=bgrins
This patch introduces 2 new prefs:
- devtools.console.stdout.chrome: if true, console API writes on stdout when
                                  used by chrome code
- devtools.console.stdout.content: console API write on stdout when used by
                                   content code.
2018-11-15 21:47:58 +01:00
Mark Banner
a26105ff45 Bug 1501662 - Add more .eslintrc.js files for test directories (dom, modules, netwerk and parser). r=mossop
Differential Revision: https://phabricator.services.mozilla.com/D9661

--HG--
extra : moz-landing-system : lando
2018-10-24 19:11:17 +00:00
Nicholas Nethercote
8478f8d66e Bug 1489047 - Change almost all DOMString occurrences in XPIDL files to AString. r=nika
Because they have almost identical semantics.

--HG--
extra : rebase_source : ea9074bcac2a1d190b88a5d1afc15997593659b7
2018-09-06 18:02:43 +10:00
Karl Tomlinson
994a8aaf0b Bug 1492014 test Console::mInnerID instead of mGlobal when needing a window id r=baku
No behavior change intended.

Differential Revision: https://phabricator.services.mozilla.com/D6382
2018-09-24 17:19:14 +00:00
Karl Tomlinson
6471490b0a Bug 1492014 remove now-unused WorkletThread::mWorkletLoadInfo r=baku
Depends on D6107

Differential Revision: https://phabricator.services.mozilla.com/D6108
2018-09-18 09:28:28 +00:00
Karl Tomlinson
f2eadaf575 Bug 1492014 get WorkletLoadInfo from global instead of thread in Console r=baku
Depends on D6106

Differential Revision: https://phabricator.services.mozilla.com/D6107
2018-09-18 09:29:15 +00:00
Karl Tomlinson
0fdde9c5ed Bug 1492014 store global as nsIGlobalObject on Console so that this may be used for Worklets also r=baku
Differential Revision: https://phabricator.services.mozilla.com/D6106

--HG--
extra : amend_source : dc4a241f4f60662c4f0e07730470375dde40aa24
extra : transplant_source : %D4%D5%8B%81b%89z%E9%5D%80o%D6u%9E%3Ep%C8%B5e%E9
2018-09-28 19:10:07 +12:00
Karl Tomlinson
887c196e5b Bug 1492014 remove unused Console::GetParentObject() r=baku
WebIDL bindings do not need this method because console is a namespace.
All methods are static.

Depends on D6104

Differential Revision: https://phabricator.services.mozilla.com/D6105
2018-09-18 09:32:11 +00:00
Narcis Beleuzu
bf9a9a6b50 Backed out 13 changesets (bug 1492014) for multiple failures. a=backout
Backed out changeset f629b66a235f (bug 1492014)
Backed out changeset 0a8510efbba3 (bug 1492014)
Backed out changeset 2798792623cf (bug 1492014)
Backed out changeset 8818f5ae0d13 (bug 1492014)
Backed out changeset 0c6b469c9618 (bug 1492014)
Backed out changeset d1654231ffb8 (bug 1492014)
Backed out changeset 5a3967f37d3f (bug 1492014)
Backed out changeset ac095c2fdd8b (bug 1492014)
Backed out changeset 4d1ba44e30ab (bug 1492014)
Backed out changeset e34938a11fab (bug 1492014)
Backed out changeset 3e142ea44140 (bug 1492014)
Backed out changeset b0f2fafdba8c (bug 1492014)
Backed out changeset d77330a1cbfa (bug 1492014)
2018-09-25 16:26:04 +03:00
Karl Tomlinson
e6d5b031cb Bug 1492014 test Console::mInnerID instead of mGlobal when needing a window id r=baku
No behavior change intended.

Differential Revision: https://phabricator.services.mozilla.com/D6382

--HG--
extra : moz-landing-system : lando
2018-09-24 17:19:14 +00:00
Karl Tomlinson
18b9edd04f Bug 1492014 remove now-unused WorkletThread::mWorkletLoadInfo r=baku
Depends on D6107

Differential Revision: https://phabricator.services.mozilla.com/D6108

--HG--
extra : moz-landing-system : lando
2018-09-18 09:28:28 +00:00
Karl Tomlinson
1bbf3f704b Bug 1492014 get WorkletLoadInfo from global instead of thread in Console r=baku
Depends on D6106

Differential Revision: https://phabricator.services.mozilla.com/D6107

--HG--
extra : moz-landing-system : lando
2018-09-18 09:29:15 +00:00
Karl Tomlinson
49a69c3443 Bug 1492014 store global as nsIGlobalObject on Console so that this may be used for Worklets also r=baku
Depends on D6105

Differential Revision: https://phabricator.services.mozilla.com/D6106

--HG--
extra : moz-landing-system : lando
2018-09-20 11:29:20 +00:00
Karl Tomlinson
b35848bfc0 Bug 1492014 remove unused Console::GetParentObject() r=baku
WebIDL bindings do not need this method because console is a namespace.
All methods are static.

Depends on D6104

Differential Revision: https://phabricator.services.mozilla.com/D6105

--HG--
extra : moz-landing-system : lando
2018-09-18 09:32:11 +00:00
Andrea Marchesini
841dd1282e Bug 1489844 - Port DOMPrefs to StaticPrefs - part 20 - devtools.enabled, r=ehsan 2018-09-10 20:36:17 +02:00
Mike Hommey
32627430f6 Bug 1489363 - Replace some string.Append* with AppendLiteral. r=froydnj
Depends on D5224

Differential Revision: https://phabricator.services.mozilla.com/D5225

--HG--
extra : moz-landing-system : lando
2018-09-07 22:12:04 +00:00
Kris Maglione
56f4830bf8 Bug 1484466: Part 2a - Remove no-op generateCI calls. r=mccr8
These stopped having any effect when we switched to ChromeUtils.generateQI,
which does not support automatic nsIClassInfo forwarding.

Differential Revision: https://phabricator.services.mozilla.com/D3707

--HG--
extra : rebase_source : 62a3690304ad7baa760c41eba777aa17b9af33f0
2018-08-18 12:38:31 -07:00
Jan de Mooij
4af62d6c9e Bug 1480678 part 7 - Use CallbackObject's callback global for realm entering in more places. r=bz 2018-08-07 14:06:44 +02:00
Jan de Mooij
e0ef865217 Bug 1479363 part 5 - Use JSAutoRealm instead of JSAutoRealmAllowCCW in remaining dom/ directories. r=mccr8 2018-08-02 08:49:00 +02:00
Jan de Mooij
80adc67aba Bug 1478955 part 1 - Rename JSAutoRealm to JSAutoRealmAllowCCW. r=luke 2018-07-28 12:12:26 +02:00
Andrea Marchesini
a053cf1c15 Bug 1476306 - Moving NullPrincipal/ContentPrincipal/SystemPrincipal under mozilla namespace - part 1 - NullPrincipal, r=ckerschb 2018-07-17 21:37:48 +02:00
Jeff Gilbert
5b753da289 Bug 1470325 - s/FooBinding/Foo_Binding/g - r=qdot
MozReview-Commit-ID: JtTcLL5OPF0
2018-06-26 17:05:01 -07:00
Jan de Mooij
45a7ade57e Bug 1469217 part 2 - Add APIs taking getter/setter objects instead of JSNatives. r=anba 2018-06-21 11:05:42 +02:00
Andrea Marchesini
037d3a703f Bug 1455256 - Port more components to WorkerRef - part 1 - WorkerProxyToMainThreadRunnable, r=asuth 2018-06-18 16:37:21 -04:00
Joel Maher
50b91c0a14 Bug 1405428 - skip-if = verify on mochitests which do not pass test-verify. r=gbrown 2018-06-10 05:01:47 -04:00
Jan de Mooij
f7fb3be6ec Bug 1466121 part 1 - Rename JSCompartment to JS::Compartment. r=luke
--HG--
extra : rebase_source : cd7140ecda54f0caa02a96f562167b3c9a107450
2018-06-07 16:44:40 +02:00
Miko Mynttinen
4c85ef17cc Bug 1465060 - Part 1: Fix warnings for std::move() use r=froydnj
MozReview-Commit-ID: HpdFXqQdIOO

--HG--
extra : rebase_source : 1e7eea4f2d4ec16ec0c559a8afb26976ddbf4d07
2018-06-01 17:59:07 +02:00
arthur.iakab
7e765f798b Backed out 2 changesets (bug 1465060) for build bustages on security/sandbox/linux/reporter/SandboxReporter.cpp
Backed out changeset 7c8905b6b226 (bug 1465060)
Backed out changeset 10446073eca8 (bug 1465060)
2018-06-03 19:25:41 +03:00
Miko Mynttinen
8d9dc85cd4 Bug 1465060 - Part 1: Fix warnings for std::move() use r=froydnj
MozReview-Commit-ID: HpdFXqQdIOO

--HG--
extra : rebase_source : 619d0e0ff63a2453c80f0c4d9beb906d43fa9b01
2018-06-01 17:59:07 +02:00
Emilio Cobos Álvarez
1e9c395548 Bug 1466168: Remove mozilla::Forward in favor of std::forward. r=froydnj
Same approach as the other bug, mostly replacing automatically by removing
'using mozilla::Forward;' and then:

  s/mozilla::Forward/std::forward/
  s/Forward</std::forward</

The only file that required manual fixup was TestTreeTraversal.cpp, which had
a class called TestNodeForward with template parameters :)

MozReview-Commit-ID: A88qFG5AccP
2018-06-02 09:33:26 +02:00
Emilio Cobos Álvarez
fffb25b74f Bug 1465585: Switch from mozilla::Move to std::move. r=froydnj
This was done automatically replacing:

  s/mozilla::Move/std::move/
  s/ Move(/ std::move(/
  s/(Move(/(std::move(/

Removing the 'using mozilla::Move;' lines.

And then with a few manual fixups, see the bug for the split series..

MozReview-Commit-ID: Jxze3adipUh
2018-06-01 10:45:27 +02:00
Andrea Marchesini
21437f85f8 Bug 1463614 - Fix intermittent failure in test_timer.html, r=me 2018-05-29 13:09:00 +02:00
Andrea Marchesini
aa542ebeee Bug 1461854 - Fixing dom/console/tests/test_timer.html allowing duration to be >= 0, r=me 2018-05-24 15:32:00 +02:00
Andrea Marchesini
7fd05a68da Bug 1461854 - dom/console/tests/test_timer.html must disable reduce-timer-precision, r=tjr 2018-05-23 16:06:31 +02:00
Andrea Marchesini
0519d22370 Bug 1459279 - Console API: Implement console.countReset(), r=bgrins 2018-05-22 11:34:41 +02:00
Jan de Mooij
80e44e8003 Bug 1461292 part 1 - Rename JSAutoCompartment to JSAutoRealm. r=bz,luke 2018-05-16 10:53:16 +02:00
Andrea Marchesini
625539c9d7 Bug 1458466 - Implement Console.timeLog(optional DOMString label = "default") - fixed an intermittent failure, r=me 2018-05-15 18:11:44 +02:00
Andrea Marchesini
325b9045d9 Bug 1458466 - Implement Console.timeLog(optional DOMString label = "default"), r=bgrins 2018-05-15 13:00:49 +02:00