Commit Graph
23 Commits
Author SHA1 Message Date
Nicolas Chevobbe 4bd90386e4 Bug 1590093 - Lazy load console components. r=Honza.
We try to lazy load all the things we know we might
not need directly when opening the console.

Differential Revision: https://phabricator.services.mozilla.com/D50800
2019-10-29 10:46:51 +00:00
Ciure Andrei e1f7e6e59b Backed out changeset 0a516296693b (bug 1590093) for causing browser_jsterm_selfxss.js to permafail CLOSED TREE 2019-10-28 17:15:50 +02:00
Nicolas Chevobbe 7d2ac33079 Bug 1590093 - Lazy load console components. r=Honza.
We try to lazy load all the things we know we might
not need directly when opening the console.

Differential Revision: https://phabricator.services.mozilla.com/D50800
2019-10-28 13:23:15 +00:00
Nicolas Chevobbe a56fb5fef6 Bug 1585923 - Rename MenuButton doc prop to toolboxDoc. r=jdescottes.
This should make it more obvious what kind of document
the component is expecting.

Differential Revision: https://phabricator.services.mozilla.com/D50240
2019-10-24 05:56:10 +00:00
Michael Ratcliffe 2afac0b5e0 Bug 1580631 - [Inactive CSS] Tooltip should hang off to right side in LTR mode r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D46284
2019-09-24 11:21:46 +00:00
Andreea Pavel d6c7e861b8 Backed out changeset b46946d6e446 (bug 1580631) dt failures at browser_html_tooltip_doorhanger-01.js on a CLOSED TREE 2019-09-20 17:41:19 +03:00
Michael Ratcliffe c41a4ac87a Bug 1580631 - [Inactive CSS] Tooltip should hang off to right side in LTR mode r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D46284
2019-09-20 10:34:29 +00:00
Yura Zenevich 35c0c6ddaa Bug 1565460 - improve accessibility and configurability of the shared menu components. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D39117
2019-08-03 23:12:58 +00:00
Victor Porof b7732ae890 Bug 1561435 - Format devtools/client/, a=automatic-formatting
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D35884
2019-07-05 11:24:38 +02: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 48dcf20430 Bug 1488721 - Prevent closing the popup menu by clicking the space of tooltip popup menu. r=birtles
Differential Revision: https://phabricator.services.mozilla.com/D9059
2018-10-18 05:48:55 +00:00
Mantaroh Yoshinaga 34b24f3485 Bug 1490358 - Hide menu popup when press the ctrl+t. r=birtles
If push the ctrl+t, browser will open the new tab. In this case,
the XUL popup panel doesn't hide automatically(autohide=false).
As the result of it, the popup menu will be displayed in the new tab
content. So this patch will hide the popup when receiving the ctr+t
shortcut in the MenuButton.

Differential Revision: https://phabricator.services.mozilla.com/D8809
2018-10-16 07:13:04 +00:00
Mantaroh Yoshinaga fd816e6326 Bug 1493659 - Skip the click event handler if touch event has occurred. r=birtles
Tapping the menu button during the panel has shown make the menu button to be unopenable. This cause reason is removing the pointer-events property before the mouse event happens.
The tapping event will happen many the event like the following:
1) touchstart
2) touchmove (Long tap only)
3) touchend
4) mousedown
5) mouseup
6) click

This patch will detect the touchend event to eat the click event.

Differential Revision: https://phabricator.services.mozilla.com/D7827
2018-10-07 17:52:11 +00:00
Gabriel Luong becc8fb549 Bug 1494162 - Part 43: Lazy load createPortal to avoid creating the children of the MenuButton. r=birtles 2018-10-04 15:46:23 -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 65e9a515c8 Bug 1476549 - Part 3. Support the children of function type on the MenuButton. r=birtles
This patch will:
 - Call the children as function when rendering if MenuButton's children property is the function.
 - Add the callback which is called when the focused item changed.

Differential Revision: https://phabricator.services.mozilla.com/D6352
2018-09-20 06:28:00 +00:00
Mantaroh Yoshinaga 2f40fdbd52 Bug 1484595 - Remove the HTMLTooltip hidden event listener before destroying the HTMLTooltip. r=birtles
MenuButton will listen the HTMLTooltip hidden event even if HTMLTooltip is
destroyed. As a result of it, the timer which issued in the MenuButton's event
listener might fail due to the target window is destroyed. (e.g., switching the
dock mode to bottom  from window mode.)

This patch will remove this event listener before destroying the HTMLTooltip.

Differential Revision: https://phabricator.services.mozilla.com/D3759
2018-08-20 07:03:07 +00:00
shindli 4b359b43ba Backed out changeset fc5c57e9b65b (bug 1484595) for linting failure on a CLOSED TREE 2018-08-20 10:38:08 +03:00
Mantaroh Yoshinaga 86f14b469b Bug 1484595 - Remove the HTMLTooltip hidden event listener before destroying the HTMLTooltip. r=birtles
MenuButton will listen the HTMLTooltip hidden event even if HTMLTooltip is
destroyed. As a result of it, the timer which issued in the MenuButton's event
listener might fail due to the target window is destroyed. (e.g., switching the
dock mode to bottom  from window mode.)

This patch will remove this event listener before destroying the HTMLTooltip.

Differential Revision: https://phabricator.services.mozilla.com/D3759
2018-08-20 07:03:07 +00:00
Mantaroh Yoshinaga 9370afd91f Bug 1477088 - Part 1. Force adding the focus to the button in order to handle the key event. r=birtles
The menu button can't receive the key event on macOS since macOS doesn't leave the focus of the menu button even if click the menu button.
So this patch will add the focus to the button when clicking the button.

Differential Revision: https://phabricator.services.mozilla.com/D2585
2018-08-08 08:16:12 +09:00
Brian Birtles bb08c95913 Bug 1474234 - Don't pass internal props onto child button in MenuButton; r=jdescottes
Otherwise we will get errors like:

console.error: "Warning: React does not recognize the `menuId` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `menuid` instead. If you accidentally passed it from a parent component, remove it from the DOM element.\n    in button (created by MenuButton)\n    in MenuButton (created by ToolboxToolbar)\n    in div (created by ToolboxToolbar)\n    in div (created by ToolboxToolbar)\n    in ToolboxToolbar (created by ToolboxController)\n    in ToolboxController"

console.error: "Warning: React does not recognize the `menuPosition` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `menuposition` instead. If you accidentally passed it from a parent component, remove it from the DOM element.\n    in button (created by MenuButton)\n    in MenuButton (created by ToolboxToolbar)\n    in div (created by ToolboxToolbar)\n    in div (created by ToolboxToolbar)\n    in ToolboxToolbar (created by ToolboxController)\n    in ToolboxController"

console.error: "Warning: React does not recognize the `menuOffset` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `menuoffset` instead. If you accidentally passed it from a parent component, remove it from the DOM element.\n    in button (created by MenuButton)\n    in MenuButton (created by ToolboxToolbar)\n    in div (created by ToolboxToolbar)\n    in div (created by ToolboxToolbar)\n    in ToolboxToolbar (created by ToolboxController)\n    in ToolboxController"

It's also not what we intend to do.

Differential Revision: https://phabricator.services.mozilla.com/D2640
2018-08-02 09:59:24 +09:00
Mantaroh Yoshinaga 0f95bb2e21 Bug 1473209 - Ignore the click event until popup is hidden. r=birtles.
The widget will hide the XUL panel when clicking to the outside of panel
automatically.
If a user clicks the MenuButton when opening the popup, the popup will hide
automatically and mouse click event will be fired on macOS and Linux.
(Windows will eat this click event since the consumeoutsideclicks of this panel
is false.)

As a result of it, the popup menu will be reopened. In order to prevent this,
this patch will disable the MenuButton until popup is hidden by using
the popuphidden event. This popuphidden event will be fired before the click
event of MenuButton, then the click event of MenuButton will be fired after
popuphidden immediately.

MozReview-Commit-ID: 42xV0aWDmkR
2018-07-27 13:38:12 +09:00
Brian Birtles f65051e51d Bug 1461522 - Add Menu components; r=jdescottes
MozReview-Commit-ID: DJVU4rRYQYU
2018-06-28 15:13:06 +09:00