Commit Graph

277 Commits

Author SHA1 Message Date
J. Ryan Stinnett
30b2b7ce44 Bug 1271084 - Apply ESLint autofixes to ignored /devtools files. r=tromey
For simple rules like function spacing, we can auto-fix these across the code
base so they are followed in a consistent way.

To generate this patch, I ran:

./mach eslint devtools --no-ignore --fix

After this, I reverted any changes to third party files that we really do want
to ignore.

MozReview-Commit-ID: 6Q8BApkAW20
2016-05-18 12:49:23 -05:00
Nicolas Chevobbe
a3ef58dc7b Bug 1271191 - Add support CSS #rgba and #rrggbbaa color syntax in the inspector. r=miker
Add support for both syntax in CssColor
Add support in value increment
Edit several tests to make sure we handle these syntaxes all across the inspector (display swatch,
color increment, unit switching, …).

MozReview-Commit-ID: FLw9va3i8H0

--HG--
extra : transplant_source : m%24%C9%E1%EFQ%18%C3%0C%8F%C6%DB%E8%E5%D2%7D%A8c%5Bl
2016-05-10 13:54:08 +02:00
Patrick Brosset
044be2e517 Bug 1210671 - Avoid CPOW to create the test page in browser_inspector_initialization.js; r=miker
MozReview-Commit-ID: Jjq5SUWZTXa

--HG--
extra : rebase_source : 885ecd284c4dc3c82ab8229b677384af80781900
2016-05-17 12:51:44 +02:00
Alexandre Poirot
9f0ddbd261 Bug 1266828 - Convert ViewHelpers.jsm into a module. r=tromey
--HG--
rename : devtools/client/shared/widgets/ViewHelpers.jsm => devtools/client/shared/widgets/view-helpers.js
2016-05-16 03:13:30 -07:00
Patrick Brosset
e4149a2ab9 Bug 1267015 - ESLint cleanup of devtools/client/styleinspector/shared/test; r=bgrins
MozReview-Commit-ID: GKnRmlqIBxb

--HG--
extra : rebase_source : 69109deafb0af8113a31832b604208817a224dbb
2016-05-13 10:16:45 +02:00
Patrick Brosset
b2488b6603 Bug 1267015 - Don't access the test content process in browser_styleinspector_tooltip-multiple-background-images.js; r=bgrins
MozReview-Commit-ID: H0kgsYzG2x0

--HG--
extra : rebase_source : 7c20c72999895ed29744b2e64166be56e0e42141
2016-05-13 09:59:33 +02:00
Patrick Brosset
96dddc3634 Bug 1260630 - ESLint cleanup of devtools/client/inspector/computed/; r=bgrins
MozReview-Commit-ID: BreSVf4bPf

--HG--
extra : rebase_source : 5ff6e97ba85c5d3bcd14db42aba10e5ee0a469e9
2016-05-13 13:09:17 +02:00
Patrick Brosset
3f8f037ded Bug 1260630 - Don't use a CPOW to get data from content in browser_computed_style-editor-link.js; r=bgrins
MozReview-Commit-ID: Jtb6C247ltM

--HG--
extra : rebase_source : e24879ef5fbb63de8c3d0f7b637eafd6a35083c5
2016-05-13 12:54:38 +02:00
Patrick Brosset
c6763c9395 Bug 1260630 - Don't use a CPOW to change style in content in browser_computed_refresh-on-style-change_01.js; r=bgrins
MozReview-Commit-ID: 5tRJTzQLl2V

--HG--
extra : rebase_source : ef28bb5449af3661fb7d26c7186f634137d55afe
2016-05-13 12:48:18 +02:00
Tom Tromey
439e22f050 Bug 1266826 - Turn Templater.jsm into a .js. r=jryans
MozReview-Commit-ID: 4T4YiOiU0oZ

--HG--
rename : devtools/shared/gcli/Templater.jsm => devtools/shared/gcli/templater.js
extra : transplant_source : N%7B%B7%E9%91%F7%CC%87%22%D0%1E%7BZ%05%16%ED%A3q%99F
2016-05-12 09:06:38 -06:00
Patrick Brosset
45c01647ea Bug 1264907 - Don't show the firstChild of the current selection in breadcrumbs; r=jdescottes
The breadcrumbs widget used to have a feature where it would show the first
child of the current selection even the DOM tree hadn't been expanded that
far yet.
This was to allow keyboard navigating the DOM through the breadcrumbs.
The breadcrumbs is a very rarely used widget and this code was unnecessarily
making things complex.
It was decided that this feature would be removed.
Instead, the breadcrumbs now act as simple linear elements in a toolbar and
you can keyboard navigate them with LEFT/RIGHT only. TAB/shift-TAB simply go
in/out of the breadcrumbs widget.

MozReview-Commit-ID: BmcaLnVBOBn

--HG--
extra : rebase_source : 1673a6c9da02cf8b3b542e4ce905ccb239250aa7
2016-04-15 12:03:33 +02:00
Alexandre Poirot
e821487c32 Bug 1268441 - Convert markup view key shortcuts to use the shortcut helper module. r=bgrins 2016-05-12 03:07:56 -07:00
Alexandre Poirot
62793e8163 Bug 1268441 - Convert inspector key shortcut to stop using XUL. r=bgrins 2016-05-12 03:07:56 -07:00
Patrick Brosset
e57616990f Bug 1069829 - 2 - Don't use cssPropertyIsValid in the rule-view UI, get the info from the server instead; r=tromey
- StyleRuleActors now parse declarations and send them within the form
- Each declaration also contains isValid flag
- Parsing is still done client side for old backends (back compat)
- Declarations are sent with the form, so updated every time the rule changes
- Also made StyleRuleActors send the declarations array for element styles, and made canSetRuleText true for this, since we can simply set the style attribute

MozReview-Commit-ID: 2nI4bRyvwwi

--HG--
extra : rebase_source : 0ccfaeb0edb0b1a60a7c0d741295d61ad66ac57e
2016-04-29 09:30:02 +02:00
J. Ryan Stinnett
e1b9ca77b0 Bug 1270619 - Add missing imports instead of using globals. r=pbro
MozReview-Commit-ID: 28Xn7N9FSZr
2016-05-09 13:35:09 -05:00
Jennifer Fong
2f312892d5 Bug 1270173 - Move protocol.js from devtools/server to devtools/shared. r=ejpbruel 2016-05-06 09:19:00 +02:00
J. Ryan Stinnett
b4f325c502 Bug 1270596 - Fix devtools after ESLint 2.9.0 upgrade. r=tromey
MozReview-Commit-ID: 7LmcHCcIv1Q
2016-05-06 10:49:44 -05:00
Julian Descottes
df759845bc Bug 1270462 - part2: tooltip toggle callback can resolve(false);r=bgrins,jsnajdr
Previously, the targetNodeCb used in TooltipToggle had an inconsistent API. If
returning synchronously, "false" would prevent the tooltip from appearing.
However, if using a promise, resolving "false" would still show the tooltip.
It was needed to reject the promise in this case to prevent the tooltip from
being displayed.

This commit makes TooltipToggle always expect a consistent return value from
this callback, whether it is synchronous, or using promises.
- true -> show the tooltip on the event target
- DOM node -> show the tooltip on the provided node
- false (or falsy value) -> do not show the tooltip

MozReview-Commit-ID: 7PIPwBJxjWO

--HG--
extra : rebase_source : 279bab30f631a3a65a93b52226c6980210abf2f1
2016-05-05 20:25:08 +02:00
Julian Descottes
87fe331949 Bug 1270462 - part1: extract devtools tooltip toggle logic to separate file;r=bgrins,jsnajdr
The code used to make the tooltip appear/disappear when hovering targets
has been extracted to a separate class that can be shared between the
current Tooltip.js implementation and the upcoming HTMLTooltip.

MozReview-Commit-ID: UYSjPFeMYK

--HG--
extra : rebase_source : 5dcca2d5887ffc98fec621092640073a0909c13f
2016-05-06 14:54:30 +02:00
James Long
e87387e53d Bug 1265775 - replace Cu.reportError with console.error in devtools client code r=tromey 2016-05-06 11:29:10 -04:00
Tom Tromey
b266a392fe Bug 1265787 - Add javascript CSS lexer to devtools. r=pbro
MozReview-Commit-ID: BgbACHTTMtX

--HG--
extra : transplant_source : %0B%F5%A3%AE%D8U%AB%5D%DF%D4%8A%90%21%22%0E%C6%BDW%06%88
2016-04-29 11:21:22 -06:00
Steve Melia
0fb164e885 Bug 1269915 - Remove right click menu from breadcrumbs;r=bgrins
MozReview-Commit-ID: 4mD2zcW7Awe
2016-05-04 22:48:15 +01:00
Julian Descottes
25f8d97318 Bug 1260419 - part2: do not hide inplace editor autocomplete popup when scrolling;r=pbro
MozReview-Commit-ID: W5N9tFCyOM

--HG--
extra : rebase_source : 516307dbc3d6142e107a10e9c3fb44ee93acc551
extra : histedit_source : d735e4b810f9648572dee5265b220dc659025814
2016-05-04 16:39:29 +02:00
Julian Descottes
c00e9f4fa4 Bug 1260419 - part1: ruleview shows more CSS suggestions, with better sorting;r=pbro
Usability changes to the ruleview autocomplete:
- max suggestions is now capped to 500 to make sure as many suggestions as possible
  as possible are displayed
- vendor-prefixed properties are moved to the end of the list
- !important is no longer the first suggested item

MozReview-Commit-ID: AOfHyqS3n8s

--HG--
extra : rebase_source : 5a4842974672bebc7427a546b4e4014201147465
extra : histedit_source : 0c008a8e7aedb60c2df0774977e54074702d555d
2016-04-07 00:43:30 +02:00
Tom Tromey
08f3ad3f7b Bug 1265876 - don't directly use Timer.jsm or timers.js in devtools; r=ochameau
MozReview-Commit-ID: HzbnNvTc5db
2016-05-04 08:02:03 -06:00
Carsten "Tomcat" Book
b64ae72562 Backed out changeset f54c4f5fd0ed (bug 1265787) 2016-05-04 12:27:37 +02:00
Tom Tromey
4383c1a8b1 Bug 1265787 - add javascript CSS lexer to devtools; r=pbro
MozReview-Commit-ID: BgbACHTTMtX

--HG--
extra : transplant_source : %A3iN%27%23%04g%91%06%2CsB%24%ABA%E9%81%D2%EA%8C
2016-04-29 11:21:22 -06:00
Brian Grinstead
c77eeb7c73 Bug 1269497 - Provide toolbox.win getter to make lines shorter in tests;r=jdescottes
MozReview-Commit-ID: 9KuWzsyHQGF
2016-05-03 07:41:20 -07:00
Nicolas Chevobbe
c6eac9c8b5 Bug 1269034 - Fix getSuggestionForQuery in inspector actor for id queries. r=bgrins
Make sure that result node id is not empty before appending it to the results

MozReview-Commit-ID: 5SuTrNf4t8v

--HG--
extra : transplant_source : E%AF%D7%A9W%DC%C6u%8B%9F%FF%00%A7%FEY%1A%7E%CA%AE%95
2016-04-30 00:36:17 +02:00
Nicolas Chevobbe
40d57bef03 Bug 1245365 - Fix markup view search with attribute selector. r=pbro
Add an ATTRIBUTE search state to better handle attribute's search.
Edit test to make sure we handle it right

MozReview-Commit-ID: ADcIJRbhjO

--HG--
extra : transplant_source : %C7R%AC%EE%2A%BA%C1%FE%B4%E4%D3%B0%D6c%B1%AB%B5%04%C6%CB
2016-04-21 21:54:03 +02:00
Julian Descottes
f41452912d Bug 1268466 - ruleview: create new rule <style> el in frame document;r=tromey
To create new rules, style elements are added to the content document.
For nodes located in an iframe, the style element should be added to the
ownerDocument of this particular node.

MozReview-Commit-ID: 7ynd7YU3WeL

--HG--
extra : rebase_source : 48e989e229b7972101c2761c881127244530273d
2016-04-30 16:41:54 +02:00
moaazsidat
45963cc05d Bug 1211613 - Re-organized the inspector context menu; r=pbro
MozReview-Commit-ID: HkSv091hpfC
2016-05-01 18:15:00 +02:00
Carsten "Tomcat" Book
a62a8252e6 Merge mozilla-central to fx-team 2016-05-02 11:39:08 +02:00
Aryeh Gregor
49d7e81abf Bug 1264270 - Parser should output attributes in source order, not reversed; r=hsivonen,bgrins 2016-05-01 15:15:26 +03:00
Michael Kohler
b5c45cdf0a Bug 1255542 - markupView.more.showAll should use a proper plural form. r=pbro, r=flod 2016-03-15 14:25:00 +01:00
Carsten "Tomcat" Book
2666074aa0 merge mozilla-inbound to mozilla-central a=merge 2016-04-28 16:30:24 +02:00
Nicolas Chevobbe
8ac826b23f Bug 820926 - Hide void-element's closing tag if the page is an HTML page. r=pbro
Though, if the element has pseudo-elements, and thus can be expanded, show
the closing tag when the void element is expanded.

MozReview-Commit-ID: 7UMMlVjYqLX
2016-04-28 01:51:46 -07:00
Carsten "Tomcat" Book
bba206d411 Backed out changeset 797e8190073f (bug 1265876) for memory leaks in browser_markup_mutation_02.js 2016-04-28 08:13:42 +02:00
Tom Tromey
ed07ccffa3 Bug 1265876 - don't directly use Timer.jsm or timers.js in devtools; r=ochameau
MozReview-Commit-ID: HzbnNvTc5db
2016-04-21 11:20:14 -06:00
Tom Tromey
f13377234d Bug 1265772 - don't use Services.console or Console.jsm in devtools; r=bgrins
MozReview-Commit-ID: Ax4EwhRVE0R

--HG--
extra : amend_source : 11297b555f1175a0be506e3ab7e72592cd3c2cd2
2016-04-19 14:05:35 -06:00
J. Ryan Stinnett
0b07b90aa6 Bug 1263258 - Require space before paren for anonymous functions. r=pbro
MozReview-Commit-ID: 2F0j45Vxn2I
2016-04-27 09:06:15 -05:00
Tom Tromey
cc930b7621 Bug 1265840 - Remove uses of Services.tm from inspector. r=pbro
MozReview-Commit-ID: DQoXLeXKUn3

--HG--
extra : transplant_source : %97%E9%DF%0DD%D5wk0%B1%07Q%10%0BI%A45JH%A6
2016-04-19 13:33:54 -06:00
Michael Ratcliffe
98177632d6 Bug 1226548 - Event listeners tooltip breaks the syntax in popup if there's a comment before event handler in JS code. r=ochameau
--HG--
rename : devtools/client/inspector/markup/test/browser_markup_events.js => devtools/client/inspector/markup/test/browser_markup_events1.js
rename : devtools/client/inspector/markup/test/doc_markup_events.html => devtools/client/inspector/markup/test/doc_markup_events1.html
2016-04-26 13:37:47 +01:00
Carsten "Tomcat" Book
287246d38d Merge mozilla-central to mozilla-inbound 2016-04-27 13:55:39 +02:00
Yoshi Huang
1f2c27b68e Bug 1263496 - Part 1: fix for @mozilla.org/nullprincipal;1 r=bholley
This fixed the locations listed by
http://searchfox.org/mozilla-central/search?q=@mozilla.org/nullprincipal;1&redirect=true
2016-04-27 18:37:58 +08:00
Ryan VanderMeulen
395004da77 No bug - Re-enable some more tests that were disabled on e10s without a tracking bug.
--HG--
extra : histedit_source : fa83d576e38f400a6ec395101ea34b58573676aa
2016-04-25 21:45:46 -04:00
Julian Descottes
435717397c Bug 1266997 - fix test browser_rules_completion-new-property_multiline.js on winXP;r=pbro
MozReview-Commit-ID: FEpmTAPxb0a

--HG--
extra : rebase_source : e09afad472c24fa112615383f57b3e176cda5a42
2016-04-25 10:10:25 +02:00
Amod Narvekar
4e7342c40c Bug 1259892: Setting the defaultTab and checking whether tab is hidden, r=pbro
MozReview-Commit-ID: 4eThr8Q0CEJ
2016-04-22 08:57:00 +02:00
Julian Descottes
917fbc1044 Bug 1245776 - part3: import shared/test/head in styleeditor/test/head;r=gl
5 tests of the styleeditor suite are importing shared/test/head.
Now that this also includes shared-head.js, it conflicts with the existing
styleeditor head file.

For now, the import was moved to the head, so it's always imported.
The tests have been updated accordingly.

Should file a follow-up to split the inspector test suites head files in a
head.js + helpers.js (see commandline/test). It should be possible to
include helpers in other tests without impact on the test lifecycle.

MozReview-Commit-ID: BU3LiEr0UtZ

--HG--
extra : rebase_source : b0b232e25f387238b5c7256691992c7fcc7ff929
2016-04-20 15:53:50 +02:00
Julian Descottes
8e94f2fd48 Bug 1245776 - part2: remove custom openInspector methods;r=gl
shared/test/head had custom methods to open the Computed & Rule view.
They did not register any test actor and could be called several times
in the same test.

In order to reuse the openInspector method from inspector/test/head, the
tests have been modified.
We are moving from
openRuleView() -> do rule view tests -> openComputedView() -> do computed view tests
to
openInspector() -> select rule view -> do rule view tests -> select computed view -> do computed view tests

A bit more verbose for the tests themselves, but this will be useful when
migrating the shared tests to using the testActor.

MozReview-Commit-ID: 94cOqhPICyI

--HG--
extra : rebase_source : f7892af19b78ecdbb759fb21d17920f0f6e0f4c6
2016-04-20 15:47:22 +02:00