The Browser Console interacts with a ChromeActor instance, which as any TabActor inherited actor,
expects to be "attached" by calling its `attach` request. isTabActor set to true ensures that.
While chrome set to true allows client codebase to enable additional behavior for chrome debugging.
MozReview-Commit-ID: 1MVLBKnluhg
--HG--
extra : rebase_source : 7e5c976c6a9690ae730fd8c32a8909e24a277ace
This passes an openLink callback to the Reps which handles the output.
MozReview-Commit-ID: L6q9wAWmwrp
--HG--
rename : devtools/client/webconsole/test/browser_webconsole_clickable_urls.js => devtools/client/webconsole/new-console-output/test/mochitest/browser_webconsole_clickable_urls.js
extra : rebase_source : d439fe0596f0fdc2b3c529814bcd07c0c08c7200
This required some changes in the ConsoleTable component. Since
it uses GripMessageBody, we need to pass it props that it might
need.
MozReview-Commit-ID: DNeBsmJqCFI
--HG--
extra : rebase_source : 34f4b6acc34fdd79b4111f07162ede46b96ae363
When the event prioritization is enabled, we'll reserve some time to process input events in each frame. In that case the synthesized input events delay the execution of normal events a lot and cause the test timeout.
MozReview-Commit-ID: 1G3ggeaZ1Os
A test needed to be fixed since we changed some things
in bucketing (proper ellipsis and bucket label fix).
MozReview-Commit-ID: HhfJcKOGO2H
--HG--
extra : rebase_source : 91163a226eaada796b884b6a8e7a0b4887b65e1d
In prevision of Promise.jsm removal, use defer helper module instead of Promise.jsm
as that's the only one feature that DOM Promise don't support.
PART3: Manual fixes
- Go manually fix: http://searchfox.org/mozilla-central/source/devtools/client/dom/dom-panel.js
which has duplicated import of defer symbol (it already used to import it)
- execute eslint, see all the places where we import of 'promise' is no longer use it
(there may be leftovers not covered by eslint that will be covered in bug 1387128)
devtools/server/tests/mochitest/inspector-helpers.js needs to keep importing promise as it is a shared test script.
- fix devtools/client/performance/panel.js and devtools/client/webconsole/console-output.js
which use loader.lazyRequireGetter(this, "promise") and miss the defer import
- fix devtools/server/worker.js to use 'worker.require(devtools/shared/defer")'
MozReview-Commit-ID: HIOB5Et87Wc
--HG--
extra : rebase_source : fe3bff8599807224fd51898e753589d4c7c1777f
In prevision of Promise.jsm removal, use defer helper module instead of Promise.jsm
as that's the only one feature that DOM Promise don't support.
PART2: Substitutes promise.defer usages with defer
$ sed -i 's/promise.defer/defer/gI' $(egrep -lir "promise.defer\(\)" devtools)
Reset modification to the following files as they are using deprecated syncable promises as we don't want to touch them.
http://searchfox.org/mozilla-central/search?q=deprecated-sync-thenables&case=true®exp=false&path=
$ git checkout devtools/client/debugger/test/mochitest/
$ git checkout devtools/shared/client/main.js
$ git checkout devtools/client/debugger/
$ git checkout devtools/server/main.js
MozReview-Commit-ID: DGN5ae68wtn
--HG--
extra : rebase_source : 57602d89b0bcc1c905bee7723e30f87fa434c6d9
In prevision of Promise.jsm removal, use defer helper module instead of Promise.jsm
as that's the only one feature that DOM Promise don't support.
PART1: Import devtools/shared/defer
$ sed -i '/require("promise")/a const defer = require("devtools/shared/defer");' $(egrep -lir "promise.defer\(\)" $(egrep -rl "require\(\"promise\"\)" devtools))
But ignore debugger as it still uses sync promises and would better be handled manually
$ git checkout devtools/client/debugger/
MozReview-Commit-ID: 7FvhNxULB2x
--HG--
extra : rebase_source : 7eacd673759d85ab88d69b6edc6dff4c7f245638
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
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
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
This adds a data-indent attribute to the message indent component
so we can target it in CSS.
MozReview-Commit-ID: DEUTHe42Pa0
--HG--
extra : rebase_source : 650e9148d26318855c985a5b6c7830338c50bc25
This is needed to:
1. force the devtools system addon installation when starting the BT instance of FF
2. avoid the addon update prompt
Another approach is to create a separate user.js pref file to fix 1. However with this
approach there is currently no way to fix 2.
MozReview-Commit-ID: palK2hION0
--HG--
extra : rebase_source : e7a70e68d359fe4a3249a6a5648a52abbde6d851
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 : b00465e7e0ef8145b341c495eb27e7f1e703d341
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 : 7feb021770c827996e276b60169b08093ecc1ff0
In this patch:
- register webide properly
- register localization
- add processing indicator in jar.mn for pref files (details below)
The preferences files still contain processing instructions, that we manually interpret when loading
prefs. Keeping the * processing indicator will avoid triggering warnings in tests scanning
javascript files for issues such as browser_parsable_script.js
MozReview-Commit-ID: 8WYUvbtMNn5
--HG--
extra : rebase_source : 18b13c0d6d1065e141650edb5a3a0b1e7b09a5f8
This also fixes a few tests that were failing due to changes
in how we now render arrays and objects in tiny mode.
MozReview-Commit-ID: 9JRjDQQ46FA
--HG--
extra : rebase_source : 7f482505647eedbe984f6e2c9efed8c26254fc07
This adds an `ownSymbols` and an `ownSymbolsLength` properties to the
grip `preview` property so we can retrieve them in the frontend.
This also refactors the newly introduced test for symbols and add a
function which test the content of the preview property in the grip.
The console test packet stubs files were updated to take this into account.
MozReview-Commit-ID: 7rPxFcS5uXE
--HG--
extra : rebase_source : dcd1189904b8f10ffb27df4c2290ac391a4f08ed
This mochitest was never added to browser.ini, and never ran on try.
I tested it locally and the test still seems to run. However the mdn
docs widget is now disabled by default and is actually not working
very well when enabled.
I propose to remove the file rather than slowing down our test suite
for this.
MozReview-Commit-ID: 4QEIdUQRgJZ
--HG--
extra : rebase_source : 4f29fd794495e9ca71f0854b9c6e07d2ae6269d5
Per definition of this bug/patch, key shortcuts can't be registered anymore.
It mostly means that add-on definition a key shortcut won't keep their key shortcut working.
This shouldn't be an issue on 57 as I don't think WebExtension addon can set a key shortcut via this DevTools API.
MozReview-Commit-ID: G5c8JzaUWoR
--HG--
extra : rebase_source : d9cda8d4af63af795e8f66d3bee7e442bd78d939
Now that devtools-browser is lazily evaluated, we have to create the widget early in devtools-startup.
MozReview-Commit-ID: JanbAPalYE1
--HG--
extra : rebase_source : 2625da986184d5a1f8b3ce293da4e16fdb5ed339
The services.js shim has been moved to devtools-core repo on GitHub
and should be removed from mozilla central.
MozReview-Commit-ID: 3uolLWuU6Lh
--HG--
extra : rebase_source : 98a0506be5df5be56ef03f98162effbf0b1142fb
We don't retrieve the indent from the MessageContainer anymore, but from the lowest-level
component where we have access to the full message data, i.e. the messages types components (e.g.
ConsoleApi, EvaluationResult, … ).
MozReview-Commit-ID: JkaIcxnyt3W
--HG--
extra : rebase_source : 3ebe764cae33348d8d807936f5dcad3f23a0aa31
Click and drag markers, circle edges, and radius edges to move them.
Double click on a polygon edge to add a new point.
Double click on a polygon point to remove it.
MozReview-Commit-ID: EbPH1pVVBOT
--HG--
extra : rebase_source : 754d9f75e55f327f448d826123c0b522d0bbe7df
In the frontend we need to know if XUL buttons in the toolbar were
triggered by a touch event, so we're passing on the inputSource
in the command event.
MozReview-Commit-ID: DMvgZULk9hT
--HG--
extra : rebase_source : c455c8ec77e439bf02c1e3e8d34a36e1fb5e3bd0
When the event prioritization is enabled, we'll reserve some time to process input events in each frame. In that case the synthesized input events delay the execution of normal events a lot and cause the test timeout.
MozReview-Commit-ID: 1G3ggeaZ1Os
Now that scoped stylesheets are no longer supported, it doesn't make sense to
include a specific copy of an HTMLTooltip stylesheet in the tooltip container.
Nothing guarantees that a given stylesheet won't be loaded more than once so
having a single one-shot import in tooltips.css is more appropriate.
MozReview-Commit-ID: 690pGNQdnwy
--HG--
extra : rebase_source : 7d7fadebf0fb20984508cbc7643998c505ec2ffd
Scoped stylesheets will stop being supported for chrome content per Bug 1345702.
Update the selectors in the stylesheets so that they can easily be loaded without the
scope attribute.
MozReview-Commit-ID: FV4tWD4SlYA
--HG--
extra : rebase_source : 63f2fce76cb6f1e7052e6e421a256c0ea8f77852
The inspect command in extension was directly calling jsterm.inspectObject and doing so bypassed
the code we implemented for the command on the new frontend (i.e. no more variable view).
This patch modifies the jsterm inspectObject function so it can do the expected behavior,
and also reverts some changes made in the original inspect command bug, so we only deal with
the new frontend code in jsterm.inspectObject.
This implied changing an extension test that was waiting for the variable view to boot-up.
The test was modified to match the tests we already have for the inspect command on the new
console frontend.
MozReview-Commit-ID: 8fZV20Mck8r
--HG--
extra : rebase_source : 59870c4bae3664aebf448acee439b918190591dc
Implements PerformanceTiming, nsITimedChannel, and devtools 'tls setup'
Also captures telemetry on this as we do for all other attributes of timedChannel
Also propogates some null transaction timings onto first real
transaction of a connection
MozReview-Commit-ID: 47TQJYVHnKC
--HG--
extra : rebase_source : a7723962986de0c2ab00d479a22c3f5fd185c8b2