Commit Graph

1040 Commits

Author SHA1 Message Date
Andrew Swan
1ab513d145 Bug 1519577 Convert toolbarbutton to a custom element r=surkov
Differential Revision: https://phabricator.services.mozilla.com/D31941
2019-05-20 10:01:02 -07:00
Gijs Kruitbosch
64566202e5 Bug 1547573 - fix sorting in and add test for themes dropdown in customize mode, r=jaws
Differential Revision: https://phabricator.services.mozilla.com/D30392
2019-05-09 18:22:53 +00:00
James Teh
fc05c5a674 Bug 1547635: PanelMultiView: Don't override keyboard navigation in context menus. r=Gijs
Normally, context menu keyboard handling takes precedence.
However, because we have a capturing window keydown listener, our listener takes precedence.
Therefore, we need to check for an open context menu and suppress our keyboard handling in this case.

Differential Revision: https://phabricator.services.mozilla.com/D29791
2019-05-08 05:18:17 +00:00
James Teh
d26dcaee2e Bug 1546633: PanelMultiView: Send mousedown event when activating a button via the keyboard. r=Gijs
Previously, we sent a command event and a click event.
Normally, the command event executes the action, then the click event closes the menu.
However, in some cases (e.g. the Library button), there is no command event handler and the mousedown event executes the action instead.

Differential Revision: https://phabricator.services.mozilla.com/D29151
2019-05-02 10:35:57 +00:00
James Teh
7c62cc8c15 Bug 1545766: PanelMultiView: Don't override keyboard navigation in embedded documents. r=Gijs
Extension panels contain embedded documents; i.e. a <browser> element.
We want users to be able to tab to these and we want them to be focused automatically if a subview is opened from the keyboard, so treat them as tabbable.
However, once an embedded document is focused, we can't manage keyboard navigation inside it, so don't try.
Previously, we tried, which meant keys were overridden even though they didn't do anything, breaking keyboard navigation in extensions altogether.

Differential Revision: https://phabricator.services.mozilla.com/D28442
2019-05-02 10:35:49 +00:00
Joel Maher
41ecc30f4a Bug 1546459 - remove subsuite=clipboard from manifests. r=ahal
remove subsuite=clipboard from manifests

Differential Revision: https://phabricator.services.mozilla.com/D28521
2019-05-01 08:16:44 +00:00
Ciure Andrei
2355f6b949 Backed out 2 changesets (bug 1545766, bug 1546633) for causing browser_PanelMultiView_keyboard.js to perma fail CLOSED TREE
Backed out changeset 041741ce1646 (bug 1546633)
Backed out changeset fbc294a6fe78 (bug 1545766)
2019-05-01 09:02:48 +03:00
James Teh
dff2e75717 Bug 1546633: PanelMultiView: Send mousedown event when activating a button via the keyboard. r=Gijs
Previously, we sent a command event and a click event.
Normally, the command event executes the action, then the click event closes the menu.
However, in some cases (e.g. the Library button), there is no command event handler and the mousedown event executes the action instead.

Differential Revision: https://phabricator.services.mozilla.com/D29151
2019-05-01 04:01:35 +00:00
James Teh
0b5ee08d3e Bug 1545766: PanelMultiView: Don't override keyboard navigation in embedded documents. r=Gijs
Extension panels contain embedded documents; i.e. a <browser> element.
We want users to be able to tab to these and we want them to be focused automatically if a subview is opened from the keyboard, so treat them as tabbable.
However, once an embedded document is focused, we can't manage keyboard navigation inside it, so don't try.
Previously, we tried, which meant keys were overridden even though they didn't do anything, breaking keyboard navigation in extensions altogether.

Differential Revision: https://phabricator.services.mozilla.com/D28442
2019-05-01 04:01:35 +00:00
Gijs Kruitbosch
15ddf1a163 Bug 1515204 - add mouseup after drop in EventUtils, r=NeilDeakin
Differential Revision: https://phabricator.services.mozilla.com/D28749
2019-04-30 12:55:23 +00:00
Gijs Kruitbosch
7f6584f7e4 Bug 1543129 - fix buttons disappearing in customize mode after using 'restore defaults', r=jaws
Differential Revision: https://phabricator.services.mozilla.com/D28719
2019-04-29 13:36:04 +00:00
Andrew Swan
a21c1c9924 Bug 1538983 Convert button xbl binding to a custom element r=bgrins
As of this change, instances of xul <button> use a custom element.
The button-base xbl binding remains for now, since it is still used
by toolbarbutton, it will be removed soon.

Differential Revision: https://phabricator.services.mozilla.com/D27742
2019-04-15 14:27:32 -07:00
Gijs Kruitbosch
c646ebf9fe Bug 1546482 - clean up added toolbars properly so editcontrols test passes, r=jaws
Differential Revision: https://phabricator.services.mozilla.com/D28661
2019-04-24 14:51:09 +00:00
Gijs Kruitbosch
558aee4033 Bug 1544447 - add support for numpad enter key and add tests to check activation works, r=Jamie
Differential Revision: https://phabricator.services.mozilla.com/D28431
2019-04-23 11:44:36 +00:00
Gijs Kruitbosch
03b31be5e6 Bug 1539984 - pass along whether a focus change was tripped by a keypress to ensure :-moz-focusring works as designed, r=Jamie
Differential Revision: https://phabricator.services.mozilla.com/D27874
2019-04-23 11:12:02 +00:00
James Teh
560861f867 Bug 1454865: PanelMultiView: When entering a subview using the keyboard, focus the first button after the Back button in the subview. r=Gijs
Differential Revision: https://phabricator.services.mozilla.com/D26067
2019-04-15 01:38:15 +00:00
James Teh
ea887cd7b3 Bug 1477673: Refactor PanelMultiView keyboard navigation to use a TreeWalker. r=Gijs,johannh
Previously, this code cached a list of controls on first use and used that for navigation.
This refactor addresses several issues:

1. There is now a separate focus order for tab/shift+tab and down/up arrows.
    This allows menulists, textboxes, etc. which use the arrow keys themselves to be focused with tab, but skipped with the arrows.
    This means the user won't fall into these controls when using the up/down arrow keys and be confused by the subsequent arrowing behaviour.

2. When a menulist, textbox, etc. is focused, the arrow keys, space and enter are now passed to the control.
    This is a better fix for handling of the arrow keys by menulists (bug 1522092).
    It also fixes left arrow in a textarea moving to the previous view instead of moving the caret (bug 1489874).

3. This improves handling of dynamic updates to the panel.
    For example, elements that are initially disabled and enabled later will be navigable.
    This is because the next element is determined dynamically by the TreeWalker, rather than using a cached list.

4. The interim fix for bug 1522092 disabled PanelMultiView keyboard navigation.
    This caused some regressions, including arrow keys/activation on the Site Identity Report a Problem link (bug 1539976) and some controls not being navigable if the Site Identity panel is opened using the mouse (bug 1539984).
    With the above fixes, we can now re-enable PanelMultiView keyboard navigation in the Site identity panel and thus fix these regressions.

5. Previously, PanelMultiView keyboard navigation was disabled in the main toolbar overflow menu.
    This is because the search box can be added to the overflow menu, which previously caused problems for the arrow keys.
    With the above fixes, we can now safely enable PanelMultiView keyboard navigation in the overflow menu.

6. PanelMultiView keyboard tests have been added.
    Previously, we relied on tests specific to various panels to exercise this functionality.

Differential Revision: https://phabricator.services.mozilla.com/D25905
2019-04-15 01:38:08 +00:00
Oriol Brufau
3f0d36baa3 Bug 1504567 - Don't prematurely insert lazy tabs in customize mode. r=dao
Differential Revision: https://phabricator.services.mozilla.com/D24657
2019-04-02 12:58:40 +00:00
Oriol Brufau
5c512c539f Bug 1540530 - Don't tear down Customize Mode when reloading about:blank. r=dao
Differential Revision: https://phabricator.services.mozilla.com/D25547
2019-04-09 17:54:01 +00:00
Cosmin Sabou
04b730e5f8 Backed out 2 changesets (bug 1477673, bug 1454865) for browser chrome failures on browser_PanelMultiView_keyboard. CLOSED TREE
Backed out changeset eca8a6e641c0 (bug 1454865)
Backed out changeset 69db665d8263 (bug 1477673)
2019-04-09 14:29:08 +03:00
James Teh
6913074384 Bug 1454865: PanelMultiView: When entering a subview using the keyboard, focus the first button after the Back button in the subview. r=Gijs
Differential Revision: https://phabricator.services.mozilla.com/D26067
2019-04-09 09:54:41 +00:00
James Teh
2cbc3ca2b2 Bug 1477673: Refactor PanelMultiView keyboard navigation to use a TreeWalker. r=Gijs,johannh
Previously, this code cached a list of controls on first use and used that for navigation.
This refactor addresses several issues:

1. There is now a separate focus order for tab/shift+tab and down/up arrows.
    This allows menulists, textboxes, etc. which use the arrow keys themselves to be focused with tab, but skipped with the arrows.
    This means the user won't fall into these controls when using the up/down arrow keys and be confused by the subsequent arrowing behaviour.

2. When a menulist, textbox, etc. is focused, the arrow keys, space and enter are now passed to the control.
    This is a better fix for handling of the arrow keys by menulists (bug 1522092).
    It also fixes left arrow in a textarea moving to the previous view instead of moving the caret (bug 1489874).

3. This improves handling of dynamic updates to the panel.
    For example, elements that are initially disabled and enabled later will be navigable.
    This is because the next element is determined dynamically by the TreeWalker, rather than using a cached list.

4. The interim fix for bug 1522092 disabled PanelMultiView keyboard navigation.
    This caused some regressions, including arrow keys/activation on the Site Identity Report a Problem link (bug 1539976) and some controls not being navigable if the Site Identity panel is opened using the mouse (bug 1539984).
    With the above fixes, we can now re-enable PanelMultiView keyboard navigation in the Site identity panel and thus fix these regressions.

5. Previously, PanelMultiView keyboard navigation was disabled in the main toolbar overflow menu.
    This is because the search box can be added to the overflow menu, which previously caused problems for the arrow keys.
    With the above fixes, we can now safely enable PanelMultiView keyboard navigation in the overflow menu.

6. PanelMultiView keyboard tests have been added.
    Previously, we relied on tests specific to various panels to exercise this functionality.

Differential Revision: https://phabricator.services.mozilla.com/D25905
2019-04-09 09:54:39 +00:00
Ciure Andrei
9ab1551f49 Merge inbound to mozilla-central. a=merge 2019-04-04 07:34:14 +03:00
Jan-Erik Rediger
5fec79a3f4 Bug 1529696 - Rename DATASET_RELEASE_CHANNEL_OPTOUT/OPTIN to DATASET_ALL/PRERELEASE_CHANNELS everywhere r=chutten
Depends on D25934

Differential Revision: https://phabricator.services.mozilla.com/D25935
2019-04-03 17:12:11 +00:00
Kris Maglione
708603304f Bug 1525762: Part 2a - Migrate built-in LWTs to static WebExtension themes. r=aswan
Differential Revision: https://phabricator.services.mozilla.com/D24627
2019-02-08 14:18:52 -08:00
Brian
83c5bc6d2e Bug 1523763 - Move tab context menu strings to FTL file loaded on-demand. r=Gijs,flod
Moved tab context menu out of browser.dtd to browser.xul except for sendPageToDevice, sendLinkToDevice, moveTabOptions, moveSelectedTabOptions, undoCloseTab. Not sure if tabbrowser.js and tabbrowser.xul are working as intended.

Differential Revision: https://phabricator.services.mozilla.com/D19312
2019-03-29 14:55:12 +00:00
Kris Maglione
51a70c87ef Bug 1525511: Part 5 - Get rid of most LWTManager gunk in tests. r=aswan
Differential Revision: https://phabricator.services.mozilla.com/D18788
2019-02-05 21:25:21 -08:00
Kris Maglione
a43c190b7d Bug 1525511: Part 2c - Stop using LightweightThemeManager for customize mode themes menu. r=aswan
Differential Revision: https://phabricator.services.mozilla.com/D18784
2019-02-05 17:23:24 -08:00
Kris Maglione
3cc8a9b2f7 Bug 1525511: Part 2b - Delete recommended theme gunk. r=aswan
Differential Revision: https://phabricator.services.mozilla.com/D18783
2019-02-05 21:20:37 -08:00
Gijs Kruitbosch
d1471c88c9 Bug 1462911 - allow for new overflown items to be the first item in the overflow list, r=jaws
Differential Revision: https://phabricator.services.mozilla.com/D24944
2019-03-26 19:14:27 +00:00
Vijay Budhram
ea307c8d64 Bug 1524665 - Add FxA avatar toolbar menu, r=gijs,eoger
Differential Revision: https://phabricator.services.mozilla.com//D20433
2019-02-23 17:56:19 +00:00
Minsoo Kim
3b71472b12 Bug 1530799 - Replaced waitForCondition function with TestUtils.waitForCondition r=johannh
Differential Revision: https://phabricator.services.mozilla.com/D22041
2019-03-06 09:43:44 +00:00
Mellina Yonashiro
668145c14f Bug 1530801 - Replace waitForCondition in browser_947914_button_addons.js withTestUtils.waitForCondition r=johannh
waitForCondition usage in the browser_947914_button_addons.js test file can be replaced by the TestUtils.waitForCondition utility function.

> The function was replaced. There was only one occurance in this file (browser_947914_button_addons.js), but may exists in other ones.

Differential Revision: https://phabricator.services.mozilla.com/D21720
2019-03-04 21:36:02 +00:00
AmberM
7a94268ddb Bug 1530778 - Replace waitForCondition in browser_88502_customize_mode_observers_disabed.js with TestUtils.waitForCondition. r=johannh
Differential Revision: https://phabricator.services.mozilla.com/D21849
2019-03-04 12:40:31 +00:00
lloan
41c815f1da Bug 1530783 - Replace waitForCondition with TestUtils.waitForCondition. r=johannh
Bug 1530783 - Replace waitForCondition with TestUtils.waitForCondition. r=johannh

Differential Revision: https://phabricator.services.mozilla.com/D21296
2019-02-28 10:41:49 +00:00
lloan
a42b6ea0db Bug 1530777 - Replace waitForCondition with TestUtils.waitForCondition. r=johannh
Bug 1530777 - Replace waitForCondition with TestUtils.waitForCondition. r=johannh

Differential Revision: https://phabricator.services.mozilla.com/D21280
2019-02-28 11:41:59 +00:00
jcit
b3623bc6f0 Bug 1530787 - Replace waitForConditon in browser_914138 with TestUtils.waitForCondition r=johannh
Differential Revision: https://phabricator.services.mozilla.com/D21391
2019-02-27 21:46:33 +00:00
Mark Banner
5d32c7d249 Bug 1522438 - Port Customizable UI tests to QuantumBar. r=mak
Differential Revision: https://phabricator.services.mozilla.com/D21031
2019-02-26 23:28:34 +00:00
Joel Maher
d1c97f8037 Bug 1527369 - re-enable many tests on windows 1803 due to invalid screen resolution whilst testing. r=gbrown
re-enable many tests on windows 1803 due to invalid screen resolution whilst testing

Differential Revision: https://phabricator.services.mozilla.com/D19535
2019-02-12 17:47:39 +00:00
Joel Maher
91c8d51ae3 Bug 1522900 - adjust manifests to allow tests to pass on windows10 1803 release. r=gbrown CLOSED TREE 2019-02-11 10:02:51 +01:00
Mark Striemer
e0c22d70df Bug 1500147 - Part 2: Record LWT telemetry in customize mode r=rpl
Differential Revision: https://phabricator.services.mozilla.com/D18002
2019-02-07 16:42:04 +00:00
Brian Grinstead
c8a487965d Bug 1487065 - Implement popup-notification as a Custom Element r=MattN
Differential Revision: https://phabricator.services.mozilla.com/D17699
2019-02-07 22:16:26 +00:00
Myk Melez
5ecc2c1225 Bug 1518283 - prohibit blank lines at the beginning and end of blocks (eslint padded-blocks) r=mossop,Standard8
Differential Revision: https://phabricator.services.mozilla.com/D17526
2019-01-30 17:26:25 +00:00
Kris Maglione
856fa07b17 Bug 1514594: Part 3 - Change ChromeUtils.import API.
***
Bug 1514594: Part 3a - Change ChromeUtils.import to return an exports object; not pollute global. r=mccr8

This changes the behavior of ChromeUtils.import() to return an exports object,
rather than a module global, in all cases except when `null` is passed as a
second argument, and changes the default behavior not to pollute the global
scope with the module's exports. Thus, the following code written for the old
model:

  ChromeUtils.import("resource://gre/modules/Services.jsm");

is approximately the same as the following, in the new model:

  var {Services} = ChromeUtils.import("resource://gre/modules/Services.jsm");

Since the two behaviors are mutually incompatible, this patch will land with a
scripted rewrite to update all existing callers to use the new model rather
than the old.
***
Bug 1514594: Part 3b - Mass rewrite all JS code to use the new ChromeUtils.import API. rs=Gijs

This was done using the followng script:

https://bitbucket.org/kmaglione/m-c-rewrites/src/tip/processors/cu-import-exports.jsm
***
Bug 1514594: Part 3c - Update ESLint plugin for ChromeUtils.import API changes. r=Standard8

Differential Revision: https://phabricator.services.mozilla.com/D16747
***
Bug 1514594: Part 3d - Remove/fix hundreds of duplicate imports from sync tests. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16748
***
Bug 1514594: Part 3e - Remove no-op ChromeUtils.import() calls. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16749
***
Bug 1514594: Part 3f.1 - Cleanup various test corner cases after mass rewrite. r=Gijs
***
Bug 1514594: Part 3f.2 - Cleanup various non-test corner cases after mass rewrite. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16750
2019-01-17 10:18:31 -08:00
Cristina Coroiu
1249724260 Bug 1515204 - disable browser_962069_drag_to_overflow_chevron.js on linux and mac for frequent failures. r=jmaher 2019-01-28 02:20:00 +02:00
Mark Banner
4d21b8103b Bug 1521707 - Move promisePopupEvent to BrowserTestUtils.jsm. r=mak
Differential Revision: https://phabricator.services.mozilla.com/D17259
2019-01-23 14:04:46 +00:00
Gijs Kruitbosch
550670e6d9 Bug 1458046 - avoid remote updates when the browser is not active and fix editcontrols_update test, r=NeilDeakin
Differential Revision: https://phabricator.services.mozilla.com/D16626
2019-01-16 16:20:43 +00:00
Dão Gottwald
efbf9bb3d4 Bug 1514505 - Remove unused urlbar-textbox-container. r=mak
Differential Revision: https://phabricator.services.mozilla.com/D14683
2018-12-18 11:16:05 +00:00
Dão Gottwald
01ebc456af Bug 1513827 - Let toolbar context menu handle nodes without ids. r=Gijs
Differential Revision: https://phabricator.services.mozilla.com/D14390
2018-12-13 14:53:18 +00:00
Gijs Kruitbosch
2e87cbb7e9 Bug 1494014 - fix icon on the lightweight theme button to be correct when changing it from the menu, r=jaws
Differential Revision: https://phabricator.services.mozilla.com/D12546
2018-11-21 17:23:05 +00:00