Promise with a capital 'P' is already available in all DevTools sandboxes.
Still a couple of letfovers:
* Modules still using `Promise.defer()` (will be handled in bug 1387123)
* devtools/shared/defer, which introduces changes in Promise unhandled exception and stacks (bug 1388054)
MozReview-Commit-ID: PBaliHFa7u
--HG--
extra : rebase_source : d148a26e14e5eb34129f5d4c75c2087952ae596f
This mechanically replaces nsILocalFile with nsIFile in
*.js, *.jsm, *.sjs, *.html, *.xul, *.xml, and *.py.
MozReview-Commit-ID: 4ecl3RZhOwC
--HG--
extra : rebase_source : 412880ea27766118c38498d021331a3df6bccc70
After Bug 1359855, the developer toggle is added to CustomizableUI via devtools-startup.
It is added after browser-delayed-startup-finished is received. However when starting
devtools with --jsconsole, devtools will be initialized before we receive the event and
the toggle will never be added to the UI.
Introducing a new flag here dedicated to the developer toggle and adding a few comments
to the devtools-startup:hookWindow() method which becomes a bit complex now.
MozReview-Commit-ID: IhPFznt0O83
--HG--
extra : rebase_source : d282e39c0588fca29813305292e53e71f93814bd
This changes the parser to use the final token of a statement list as
it's end location. This works around some confusing behavior, such as a
breakpoint firing on the marked line:
<script>
if (1 !== 1) {
console.log("dead code!?"); // set breakpoint here
}
</script>
MozReview-Commit-ID: 3Sk1ERw5Q6z
--HG--
extra : rebase_source : 6c6338ca183518baec6ccfcb9ae17e24cf644c97
Before trying to migrate Browser Toolbox profile dirs, ensure the old and new
dirs are actually different. This avoids an issue where we were constantly
"migrating" the profile to the same place, effectively deleting it on every run.
MozReview-Commit-ID: FUAb2G21nbV
--HG--
extra : rebase_source : 32c6425036196675322c6a5422a6edf8a8aa4498
From console/net/main.js we are calling loadSheet from sdk/stylesheet/utils.
This API needs a real window object to work, but now that devtools are loaded
as a system addon, by default the global object is a sandbox wrapper.
Use the window object which points to the actual Window instead.
MozReview-Commit-ID: LxDNfDiOso3
--HG--
extra : rebase_source : 375ad339788354a9787cbba648155319edf8b9be
extra : source : 7827d2406fc608386e13fbb0296b2136f4a0d355
This file takes care of the layout for stack traces, which can be displayed
in the console (for errors, console.trace, …).
The file was declared in webconsole.xul but not ported in webconsole.xhtml.
MozReview-Commit-ID: FFXAB14XZ6J
--HG--
extra : rebase_source : da956c54d130cd01553451da1d895b606bb4499f
This adds several tests to make sure we can expand Sets and Maps entries, and that we manage
those properties in the store as expected.
We also add a stub for a Set object and take this as an opportunity to fix the stub name.
MozReview-Commit-ID: ChhIHKMPINF
--HG--
extra : rebase_source : 89e5216605f77fb3812b3297bb95b6d3fc10de49
Add getObjectEntries and loadObjectEntries as props for the ObjectInspector so
we can display entries on Maps and Sets.
MozReview-Commit-ID: Cy6SjxwclHI
--HG--
extra : rebase_source : 02b4eb11f45f25eab9af7e640939177ab1c0f0fc
If a devtools entry point isn't hit in a test (toolbox open, keyboard shortcut,
opening the web dev menu, etc), then things like the menu items aren't installed.
This is for performance reasons (Bug 1359855), but it means that some tests
may fail when run alone. Prevent that from happening by forcing devtools to start
up in shared-head.js.
This causes certain tests to fail when run alone if they don't open the tools
MozReview-Commit-ID: ANuUhYXIbSF
--HG--
extra : rebase_source : f8a20a7eabfdbbfe51ecaf2ea8c59a4fcf41e695
This adds several tests to make sure we can expand Sets and Maps entries, and that we manage
those properties in the store as expected.
We also add a stub for a Set object and take this as an opportunity to fix the stub name.
MozReview-Commit-ID: ChhIHKMPINF
--HG--
extra : rebase_source : 5aba016c0a231032dc411aa4bd01d059e07ebd79
Add getObjectEntries and loadObjectEntries as props for the ObjectInspector so
we can display entries on Maps and Sets.
MozReview-Commit-ID: Cy6SjxwclHI
--HG--
extra : rebase_source : df3e2cd1c0be550322953cb6141948b5893a2370
This adds a simple wrapper for the source map service. This wrapper
logs errors using console.error, preserving the status quo from before
this series.
MozReview-Commit-ID: 2ckUZaerrcJ
--HG--
extra : rebase_source : 9cffca5169be005c09899a581c0d6c0738df146a
DevTools preferences are loaded dynamically by calling DevtoolsPreferences.loadPrefs().
We can not preload them when the addon starts, otherwise this will slow down the startup
of Firefox.
But jsonview's converter-observer needs to check preferences to check if jsonview is
enabled very early. Moving devtools.jsonview.enabled to a separate preferences file
that is still processed by firefox fixes the issue.
The downside is that this pref will keep following m-c's release cycle and not the addon's.
But it is so generic it should not be a big issue.
MozReview-Commit-ID: HrD5IVe54Ks
--HG--
extra : rebase_source : bb85aa12ec92db7d11abdb002f0429123b173afd
extra : source : 9622410d90ad264933ee7d1147ed655615ac4a19
With Stylo, an import rule from a cycle _will_ have a `styleSheet` object, so we
need to also check the sheet's ancestors to see if the URL is unique.
MozReview-Commit-ID: B33REaSGGYU
--HG--
extra : rebase_source : d6113d802d5197c73510ac3fa3b6cfb31d29c609
Remove previous helper APIs:
- currentFlavors()
- getData()
The only consumer for both APIs was in devtools/cient/inspector/inspector.
The logic was:
- call currentFlavors()
- if clipboard contains:
- "text/unicode"
or
- "text/html" but not "image/png"
- then call getData()
But actually calling getData() without any argument means that unless "image/png"
flavor is available, we will always use the "text/unicode" flavor.
(see current code for sdk helper: http://searchfox.org/mozilla-central/rev/09c065976fd4f18d4ad764d7cb4bbc684bf56714/addon-sdk/source/lib/sdk/clipboard.js#204-209)
If the text/unicode flavor was available at the same time as image/png, the code
would have returned the image data, which is probably not what we expect in the
context of the inspector.
I think we should explicitly request for text/unicode. So this patch introduces
a new getText() api in the devtools clipboard helper, which is a simplified version
of the sdk get() helper. We could always extend it to also support text/html.
MozReview-Commit-ID: E3JVj9boVKe
--HG--
extra : rebase_source : 3f1aecd05dacba5cd1a3af6025bbf82d51d49821
This adds a method that can be called by the toolbox to log something to
the web console.
MozReview-Commit-ID: GpZtWwNVVGO
--HG--
extra : rebase_source : 37d2336bc1dbf5a8fd35d280c349044f1d06cd4c