Commit Graph
425 Commits
Author SHA1 Message Date
Michael Ratcliffe 21c448c586 Bug 1509107 - Debugger icons missing from event bubble popup r=pbro
Updated to the new path and found a filter that gives us the exact colours we had previously in both light and dark mode.

Differential Revision: https://phabricator.services.mozilla.com/D12660
2018-11-23 15:25:29 +00:00
yulia 595fd05e97 Bug 1508655 - BoxModel highlighter move nodeHighlighter to highlighterFront; r=ochameau
Depends on D12319

Differential Revision: https://phabricator.services.mozilla.com/D12320
2018-11-23 10:50:21 +00:00
yulia fb8bc13fdb Bug 1508655 - BoxModel highlighter split domGrip methods to make them more closely related to the walker; r=ochameau
Differential Revision: https://phabricator.services.mozilla.com/D12319
2018-11-23 10:49:29 +00:00
Razvan Caliman 4c2b42b15d Bug 1507749 - Account for changing TextProperty when editing inline styles. r=pbro
The patch for https://bugzilla.mozilla.org/show_bug.cgi?id=1467076 discards previous TextProperty instances for the element's inline style when the inline style is updated.

On start, the Shape Path Editor kept a reference to the original TextProperty instance. This outdated instance caused the update mechanism of the Shape Path Editor to fail.

This patch fixes the issue by keeping metadata (index and property name) about the TextProperty to re-identify the correct one when needed instead of relying on a potentially outdated reference.

Differential Revision: https://phabricator.services.mozilla.com/D12157
2018-11-20 15:19:47 +00:00
Julian Descottes 7674d57438 Bug 1501918 - Restore tooltip size when updating Variable and BrokenImage content;r=pbro
Another regression linked to removing setContent API on HTMLTooltip.
The initial feedback to remove the method was from me, because we started seeing
two ways to set the content of the tooltip (DOM APIs or setContent) and I prefered
keeping only one. However the DOM approach still almost forces you to call setContentSize
in case your tooltip instance is shared for different content.

This is the case for the preview tooltip, which is used for CSS variables, fonts and image
previews. Maybe we should revisit the decision to remove this setContent API

Differential Revision: https://phabricator.services.mozilla.com/D9752
2018-10-25 09:44:18 +00:00
Julian Descottes c3f529eba0 Bug 1501622 - For consistency, clear innerHTML in SwatchTooltips;r=pbro
Depends on D9648

Note that this is not strictly necessary since the set* methods are only called when
the Swatch tooltips are built, so they always operate on "new" HTML Tooltips. But
since this is not very self explanatory I think it will be less surprising to be
on the safe side and clear innerHTML in the methods directly.

Differential Revision: https://phabricator.services.mozilla.com/D9649
2018-10-24 13:37:17 +00:00
Julian Descottes 7ea59e1beb Bug 1501622 - Cleanup CSS variable preview tooltip content when hovering new variable;r=pbro
Differential Revision: https://phabricator.services.mozilla.com/D9648
2018-10-24 12:50:42 +00:00
Mark Banner 3d6aaad3f5 Bug 1486741 - Enable ESLint rule comma-dangle for all of mozilla-central (automatic fixes). r=mossop
Differential Revision: https://phabricator.services.mozilla.com/D8389
2018-10-19 12:55:39 +00:00
Mantaroh Yoshinaga 5fb2c6a28f Bug 1485501 - Change the calculated viewport if anchor element is displayed at second screen. r=birtles
If we displayed the devtools across the second screen, the Screen.availLeft
might be not zero. I.e., Screen.availLeft point to second screen's left.
The HTMLTooltip does't consider this case, so this patch will change the
viewpor's left and right position if the left of anchor element is bigger than
screen.right.

Differential Revision: https://phabricator.services.mozilla.com/D8183
2018-10-16 01:16:59 +00:00
Brian Grinstead 8618750af7 Bug 1492613 - Use document.createXULElement in performance tool and scratchpad when we explicitly expect XUL elements to be returned;r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D8236
2018-10-10 15:18:59 +00:00
Gabriel Luong 764b34dd31 Bug 1494162 - Part 28: Lazy initialize TooltipToggle in HTMLTooltip. r=jdescottes 2018-10-01 11:24:41 -04:00
Gabriel Luong ff74a1316f Bug 1494162 - Part 25: Lazy load the modules in HTMLTooltip. r=jdescottes 2018-10-01 11:24:21 -04:00
Mantaroh Yoshinaga 6f7df8a1ac Bug 1472942 - Part 2. Add setContentSize() instead of setContent() in HTMLTooltip. r=birtles
This patch will remove setContest(), and change the following things instead of this:

 * Use HTMLTooltip.panel.appendChild() instead of HTMLTooltip.setContent().
 * Add HTMLTooltip.setContetnSize() to specify the panel size if need this.

Differential Revision: https://phabricator.services.mozilla.com/D7044
2018-09-27 07:14:55 +00:00
Mantaroh Yoshinaga 6ce4ecfe06 Bug 1472942 - Part 1. Remove unused paramter of HTMLTooltip.show from SwatchBaseEditorTooltip. r=jdescottes
SwatchBaseEditorTooltip specify the "topcentor bototmleft" to second parameter
of HTMLTooltip.show(). However, this parameter will ignore since show() function
require the second parameter as the object, not the string.

Bug 1307481 comment 42 has pointed out this parameter.

Differential Revision: https://phabricator.services.mozilla.com/D7043
2018-09-27 07:15:18 +00:00
yulia c7fe6da3a5 Bug 1447487 - remove all uses of GCLI eyedropper; r=ochameau
Summary:
this removes references to GCLI in the inspector front and from the browser menu, leaving
no further uses of gcli eyedropper

Test Plan: mochitests

Reviewers: ochameau

Tags: #secure-revision

Bug #: 1447487

Differential Revision: https://phabricator.services.mozilla.com/D3614
2018-08-17 16:55:01 +02:00
Gurzau Raul 421f1935ed Backed out 3 changesets (bug 1447487, bug 1485374) for failing at browser_ext_devtools_panels_elements_sidebar.js and /mochitest/test_inspector-pick-color.html on a CLOSED TREE
Backed out changeset 82ef44f87f72 (bug 1447487)
Backed out changeset d8a1c6a80a59 (bug 1447487)
Backed out changeset d4761bb0096a (bug 1485374)
2018-08-30 21:31:53 +03:00
yulia 0e8fc89f60 Bug 1447487 - remove all uses of GCLI eyedropper; r=ochameau
Summary:
this removes references to GCLI in the inspector front and from the browser menu, leaving
no further uses of gcli eyedropper

Test Plan: mochitests

Reviewers: ochameau

Tags: #secure-revision

Bug #: 1447487

Differential Revision: https://phabricator.services.mozilla.com/D3614
2018-08-17 16:55:01 +02:00
Mantaroh Yoshinaga c59e960b22 Bug 1472931 - Drop the autofocus feature of HTMLTooltip. r=birtles
This feature is no longer used. So this patch will remove this feature.

Differential Revision: https://phabricator.services.mozilla.com/D4052
2018-08-27 01:35:55 +00:00
Brian Grinstead c8b3483e82 Bug 1479538 - Rewrite non-test callers of document.createElementNS(XUL_NS, ...) to use document.createXULElement(...);r=paolo
Differential Revision: https://phabricator.services.mozilla.com/D3275
2018-08-14 16:22:44 +00:00
Julian Descottes 02afaa9954 Bug 1349416 - Only delay removeEventListener when hiding after mouseup;r=birtles
The inplace-editor is programmatically hiding the autocomplete-popup
on TAB and notifies the caller. The caller (eg rule view) will trigger
a click on the next focusable element immediately after that.

If the HTMLTooltip is still consuming outside clicks at that point
the click will be swallowed and the new inplace-editor cannot be created.

Depends on D2661

Differential Revision: https://phabricator.services.mozilla.com/D2662
2018-08-03 11:02:45 +00:00
Julian Descottes 5413bfe088 Bug 1349416 - Hide HTMLTooltip on mouseup rather than on click;r=birtles
A click event is only fired if the element on which mousedown and mouseup
happened are the same. If this is not the case, the HTMLTooltip will not
be able to hide itself.

Listening to mouseup makes the behavior more consistent but forces the
hide() method to be always asynchronous, while before it was only
asynchronous for tooltips using the XULWrapper.

Depends on D2660

Differential Revision: https://phabricator.services.mozilla.com/D2661
2018-08-03 11:01:51 +00:00
Bogdan Tara b03e56131c Backed out 3 changesets (bug 1349416) for Dev Tools failures CLOSED TREE
Backed out changeset ec5ee2990e21 (bug 1349416)
Backed out changeset c4f8eccf14dc (bug 1349416)
Backed out changeset b7e80d3a6810 (bug 1349416)
2018-08-03 12:33:32 +03:00
Julian Descottes d81a4c84d3 Bug 1349416 - Only delay removeEventListener when hiding after mouseup;r=birtles
The inplace-editor is programmatically hiding the autocomplete-popup
on TAB and notifies the caller. The caller (eg rule view) will trigger
a click on the next focusable element immediately after that.

If the HTMLTooltip is still consuming outside clicks at that point
the click will be swallowed and the new inplace-editor cannot be created.

Depends on D2661

Differential Revision: https://phabricator.services.mozilla.com/D2662
2018-08-03 07:05:51 +00:00
Julian Descottes f507e8c31b Bug 1349416 - Hide HTMLTooltip on mouseup rather than on click;r=birtles
A click event is only fired if the element on which mousedown and mouseup
happened are the same. If this is not the case, the HTMLTooltip will not
be able to hide itself.

Listening to mouseup makes the behavior more consistent but forces the
hide() method to be always asynchronous, while before it was only
asynchronous for tooltips using the XULWrapper.

Depends on D2660

Differential Revision: https://phabricator.services.mozilla.com/D2661
2018-08-03 07:05:43 +00:00
Dave Townsend 7c2cace29b Bug 1479050: Migrate a number of call-sites to use document.createXULElement. r=bgrins
Differential Revision: https://phabricator.services.mozilla.com/D2489
2018-07-31 19:13:38 +00:00
Julian Descottes c035502db8 Bug 1479006 - Move old devtools tooltip widget to debugger folder;r=nchevobbe
MozReview-Commit-ID: ATHQoGbcX2b
2018-07-27 16:59:24 +02:00
Boris Zbarsky 3af9dccacb Bug 1476145 part 4. Stop using getInterface(nsIDOMWindowUtils) in devtools. r=bgrins 2018-07-24 19:47:41 -04:00
Julian Descottes 7d398985fa Bug 1476647 - Fix TableWidget scroll position calculation;r=miker
MozReview-Commit-ID: Kn9PQMXG8bC
2018-07-18 18:01:29 +02:00
Margareta Eliza Balazs 1dbf998512 Backed out changeset 627f2adec73b (bug 1476647) for causing failures in devtools/client/storage/test/browser_storage_overflow.js 2018-07-19 09:05:35 +03:00
Julian Descottes aeb6c90ed6 Bug 1476647 - Fix TableWidget scroll position calculation;r=miker
MozReview-Commit-ID: Kn9PQMXG8bC
2018-07-18 18:01:29 +02:00
Emma Malysz e37284b753 Bug 1454358, removes unneccessary implementation of ScrollBoxObject rr?enndeakin+6102 r=bz,enndeakin+6102
MozReview-Commit-ID: LBQ0RoS0ZVc
2018-06-25 10:11:31 -07:00
Bogdan Tara f309a9ced1 Backed out changeset b099e7e0b264 (bug 1454358) for build bustages on Element.h CLOSED TREE 2018-07-12 01:50:53 +03:00
Emma Malysz daa1500e80 Bug 1454358, removes unneccessary implementation of ScrollBoxObject rr?enndeakin+6102 r=bz,enndeakin+6102
MozReview-Commit-ID: LBQ0RoS0ZVc
2018-06-25 10:11:31 -07:00
Brian Birtles 8e130c4211 Bug 1461522 - Add a mechanism to allow updating an HTMLTooltip's size and position; r=jdescottes
MozReview-Commit-ID: 4SDxlTTFp8E
2018-06-28 15:13:05 +09:00
Brian Birtles a7944f6a04 Bug 1461522 - Honor ui.popup.disable_autohide setting in HTMLTooltip; r=jdescottes
MozReview-Commit-ID: ReYYKPYaVm
2018-06-28 15:13:05 +09:00
Brian Birtles d9b05e9f46 Bug 1461522 - Add ID and class properties to HTMLTooltip; r=jdescottes
In particular, the ID allows us to associate the tooltip with the button that
triggers it using the aria-controls attribute.

MozReview-Commit-ID: ArjH2s5JNlC
2018-06-28 15:13:05 +09:00
Brian Birtles b70afbc6cb Bug 1461522 - Add focus() and focusEnd() methods to HTMLTooltip; r=jdescottes
We will use these methods later when we put menu content inside HTMLTooltip in
order to set the initial focus.

MozReview-Commit-ID: HR02wg543gP
2018-06-28 15:10:42 +09:00
Brian Birtles 5f831ad41b Bug 1461522 - Factor out a focusableSelector utility; r=jdescottes
We will use this later when we introduce a MenuList class since it will want to
manage focus for its menu items.

This patch also extends the definition of focusable elements somewhat.

MozReview-Commit-ID: 3shnC0t79rF
2018-06-28 15:10:27 +09:00
Brian Birtles 4c18f72eed Bug 1461522 - Add doorhanger type to HTMLTooltip; r=jdescottes
MozReview-Commit-ID: 6Oq9qauwngX
2018-06-28 15:04:13 +09:00
Brian Birtles 5d4d25e90b Bug 1461522 - Allow { height: "auto" } in HTMLTooltip setContent and make it the default; r=jdescottes
The current default value for height of Infinity has the unfortunate side
effect that, when combined with using a XUL wrapper, there will be a large
filler element stretching vertically on one side of the tooltip that effectively
neuters all content beneath it. While this is probably fine for tooltips that
are shown on hover, it is problematic if we want to use this for DevTools menus
because it means the user is unable to click anything above/below the menu so
long as it is open (which can be particularly problematic once we make
HTMLTooltip support the "Disable popup autohide" feature"). Even if we were to
decide that clicks outside the tooltip should be consumed anyway we would still
have the problem that hover styles don't apply in this "dead" region.

As a result, this patch makes the { height: Infinity } behaviour opt-in for
those tooltips that really need it. For most uses, however, a height calculated
when the tooltip is shown should be sufficient (and later in this patch series
we will add a mechanism to HTMLTooltip to explicitly request it recalculate its
size and position in response to content changes).

This patch introduces the { height: "auto" } mechanism and also reverses the
order in which size/position properties are calculated to match the regular
manner in which layout is performed: widths first, then heights.

MozReview-Commit-ID: 7BeVkxGVhYn
2018-06-28 15:03:57 +09:00
Brian Birtles f4f8b0b9fd Bug 1461522 - Fix some comments in HTMLTooltip.js; r=jdescottes
MozReview-Commit-ID: F01ofl9u5lR
2018-06-28 14:56:30 +09:00
Brian Birtles c944837eb9 Bug 1461522 - Use the currentZoom as opposed to the pref value; r=jdescottes
In a couple of places in DevTools we read back the value of the
"devtools.toolbox.zoomValue" pref and take that to be the zoom value. However,
at certain zoom levels these two can differ: the pref value representing the
ideal zoom and currentZoom giving the actual zoom value in use.

This patch makes us use the actual zoom value in the two places where this
occurs.

Unfortunately, we cannot easily adjust the browser_html_tooltip_zoom.js test for
this since it uses a separate XUL document that does not take into account the
pref value---as a result that test directly sets the currentZoom on the separate
doc and hence this problem won't occur.

Instead, this patch adjusts the browser_toolbox_zoom_popup.js test since the
toolbox menu positioning uses the same problematic pattern so we can reproduce
the bug in the browser_toolbox_zoom_popup.js. (This patch fixes both
occurances of this pattern.)

At least locally browser_toolbox_zoom_popup.js passes for me with a zoom of 1.5
but fails with a zoom of 1.4. Similarly in my testing of HTMLTooltip, zoom
values such as 1.2 and 1.4 often show significant misalignment whilst a zoom of
1.3 or 1.5 is fine.

With the code changes in this patch, the test passes with any given zoom factor.

(This patch also incidentally replaced isNaN with the more robust Number.isNaN.)

MozReview-Commit-ID: JmlRoidARVp
2018-06-28 14:55:48 +09:00
Brian Birtles baf1fba99e Bug 1461522 - Make HTMLTooltip position the arrow correctly in RTL mode; r=jdescottes
Currently the arrow offset is not correctly positioned in RTL mode as evidenced
by the test case included in this patch (which fails without the code changes
included in this patch).

This patch logicalizes the calculations for positioning the tooltip which fixes
this and other issues when using RTL mode and will make it easier to introduce
a new "doorhanger" type tooltip later in this patch series.

MozReview-Commit-ID: BQXhDHbPTbl
2018-06-28 14:52:10 +09:00
Razvan Caliman c209068881 Bug 1454317 - Reference correct shape swatch element after editing value in rule view. r=gl
MozReview-Commit-ID: LwF3XsE6yEs
2018-06-18 20:11:05 +02:00
Blake Kaplan bd5cecf60f Bug 1186265 - Move devtools over to getBounds(). r=pbro
This leaves getAdjustedQuads alone because it lives in its own world and its
result gets sent over IPC. That leaves things in a bit of an intermediate
state, but that should be OK for now.

MozReview-Commit-ID: DH6eGqCFhPr
2018-06-04 16:41:43 -07:00
Markus Stange c75d5069d8 Bug 1462784 - Update the devtools performance panel for the new category list. r=gregtatum
MozReview-Commit-ID: HwRFEfgA4L
2018-05-23 23:11:41 -04:00
Csoregi Natalia 27ccec9c4c Backed out 18 changesets (bug 1462784) for ESlint failure on FlameGraph.js:1297. CLOSED TREE
Backed out changeset 79556798ff9f (bug 1462784)
Backed out changeset 88321efb673b (bug 1462784)
Backed out changeset 7880f9dc7023 (bug 1462784)
Backed out changeset 71fe35fd1f7e (bug 1462784)
Backed out changeset a543b94b049a (bug 1462784)
Backed out changeset d1ca8b0f2221 (bug 1462784)
Backed out changeset 68eabfbf3c16 (bug 1462784)
Backed out changeset 34e71c789903 (bug 1462784)
Backed out changeset 6fe79d1ca1bd (bug 1462784)
Backed out changeset e5ad2e525ea9 (bug 1462784)
Backed out changeset 329645ff1e23 (bug 1462784)
Backed out changeset e09c38853172 (bug 1462784)
Backed out changeset 0663d1a6d2da (bug 1462784)
Backed out changeset 106967fc29d2 (bug 1462784)
Backed out changeset 99b4a433a8e5 (bug 1462784)
Backed out changeset 1d38a4cf5a4a (bug 1462784)
Backed out changeset 692017229de6 (bug 1462784)
Backed out changeset c2911a626671 (bug 1462784)
2018-06-01 23:42:00 +03:00
Markus Stange dd8f85c69f Bug 1462784 - Update the devtools performance panel for the new category list. r=gregtatum
MozReview-Commit-ID: HwRFEfgA4L
2018-05-23 23:11:41 -04:00
Julian Descottes 9456167901 Bug 1454696 - Fix leftover issues for prefer-const;r=yulia
MozReview-Commit-ID: JwOXoqw2mks
2018-06-01 12:19:35 +02:00
Julian Descottes 82711b9a8f Bug 1454696 - Run eslint --fix for prefer-const;r=yulia
MozReview-Commit-ID: F6xUXCgdRE4
2018-06-01 12:36:09 +02:00