FILE_FLAG_DELETE_ON_CLOSE had the wrong semantics, rendering the lock
file unusable after it had been closed once.
Delete the lock file in the uninstaller as a simple alternative (given that
the lock file is not in a temporary location on Windows).
For a test I returned to the older form of
test_backgroundtask_update_sync_manager which initially exposed the issue:
It expects the background task to be able to detect the xpcshell instance
after running resetLock, which failed before this fix.
I also extended the original updateSyncManager test to run the second
copy twice, which also catches the issue.
Differential Revision: https://phabricator.services.mozilla.com/D109565
This commit adds a new command line option |-xpcshell| that, when passed, will
run an xpcshell instead of launching a full Gecko instance.
This command line option is restricted to org.mozilla.geckoview.test for now,
as it's really hard to use and not really a usecase outside mozilla. We can
revisit this if there's interest.
Differential Revision: https://phabricator.services.mozilla.com/D106211
This patch changes the value of an empty `<input type=file>` control as obtained from the `FormData` API, which used to be an empty string, to be a `File` object with empty contents, whose name is the empty string and whose type is `"application/octet-stream"`.
Differential Revision: https://phabricator.services.mozilla.com/D106605
Goals:
* Proton is renaming error.svg to critical-fill.svg, leaving critical.svg confusing in the whole icon set.
* Reducing the amount of toolkit icons to make it easier to design/name/swap in the new proton icons & reduce installer size
* New icon looks better too (improved contrast for light theme)
Differential Revision: https://phabricator.services.mozilla.com/D109232
This migrates WebNavigation.jsm to use messages from PExtensionsParent
generated by the native WebNavigationContent class, and removes the now-unused
WebNavigationContent.js frame script.
Differential Revision: https://phabricator.services.mozilla.com/D103217
This ports the last remaining piece of WebNavigationContent.js, the
DOMContentLoaded event listener, to C++ and adds IPC messages to notify the
parent process of the events. Linkage between the parent IPDL endpoints and
the parent WebNavigation.jsm listeners is added in a subsequent patch.
Differential Revision: https://phabricator.services.mozilla.com/D103216
This ports the WebProgressListener logic from WebNavigationContent.js to the
C++ implementation, and adds IPC messages to send them to the parent process.
Linkage between the parent IPDL endpoints and the listeners in
WebNavigation.jsm is added in a subsequent patch.
Differential Revision: https://phabricator.services.mozilla.com/D103215
This is a skeleton class which will be instantiated at startup in each
process, and eventually track the same events that the deprecated
WebNavigationContent.js frame script currently tracks.
Actual implementation is added in follow-up patches.
Differential Revision: https://phabricator.services.mozilla.com/D103213
This is the start of an actor which will be automatically instantiated in the
parent and each content process which can be used to route most process-level
IPC traffic needed by the extensions framework. It should allow the extensions
framework to keep its IPC glue close to the code that uses it, and simplify
matters for child-side code which needs to run in both parent and content
processes.
Differential Revision: https://phabricator.services.mozilla.com/D103212
`AutoScrollParent` starts autoscroll even if the requested tab has already
been in background tab. In this case, it does not make sense to start
autoscrolling in new foreground window since it may not be scrollable.
Additionally, our `mousedown` event default action activates the DOM window,
but in the DuckDuckGo's case, focus shouldn't be backed to the clicked tab.
Differential Revision: https://phabricator.services.mozilla.com/D106590
This restyling mainly focuses on the text inputs, but also adjusts some
margins so that they apply more consistently between permission panels
and the password panel.
Differential Revision: https://phabricator.services.mozilla.com/D109105
I was confused by the old flag `this._ignoreMouseEvents`. It's now set to
`true` by `startAutoscroll`, but `stopScroll` does not set it to `false`.
Instead, `this._scrollable` is available for this purpose.
Then, the test does not pass only on 32bit Windows and macOS. The failure is,
when clicking on left mouse button, `click` event is fired in the content.
The difference from the other platforms, the click is handled by APZ on them.
Therefore, there is no chance to consume click event in `AutoScrollParent`,
`AutoScrollChild` nor `browser-custom-element`.
Differential Revision: https://phabricator.services.mozilla.com/D107324
Chrome behaves like this:
1. When user starts autoscroll with a middle click, `mousedown` and `mouseup`
are fired, but `auxclick` nor `paste` event is not fired.
2. When user ends autoscroll with a left click, only `mouseup` event is fired.
I.e, `mousedown` nor `click` event is not fired.
3. When user ends autoscroll with a middle click, only `mouseup` event is fired.
I.e., `mousedown`, `auxclick` nor `paste` events is not fired.
4. When user ends autoscroll with a right click, `mouseup` and `contextmenu`
events are fired, but `mousedown` and `auxclick` events are not fired.
This patch emulates these Chrome's behavior as far as possible. However,
unfortunately, we cannot do exactly same behavior without some big patches
because each widget (`nsWindow` or `nsChildView`) discards a mouse event
which rolled up a widget before dispatching it into the DOM. Therefore,
for now, this patch does not fix the following issues:
1. `mousedown` event is not fired in content when clicking outside the
autoscroller to close it except when pressing the secondary button or on any
buttons on Linux.
2. `mouseup` event is not fired in content when clicking outside the
autoscroller to close it except when pressing the primary button macOS.
3. `click` event and `auxclick` events are fired when clicking outside the
autoscroller with the secondary button.
So, the middle button `click`/`auxclick` events and `paste` event which is
reported to the bug won't be fired with this patch. I'll file follow up bugs.
Differential Revision: https://phabricator.services.mozilla.com/D104652
* We make some changes to heuristicsRegexp.js to improve accuracy. (Nothing else uses these regexps, so they're safe to change.) The commenting out of some languages in the expiration fields are because they caused a lot of false positives, according to Daniel Hertenstein's recollection. In any case, we've never preffed CC autofill on for those languages.
* Delete a few tests from test_known_strings.js and one from test_getInfo.js, which were testing for the presence of regexes we removed.
* Delete tests of CC autofill against third-party sites. These tests no longer work as xpcshell tests, since Fathom expects full layout and style information. The spirit of these tests is maintained by adding these pages to Fathom's training, validation, and testing corpora at 2bfcdf23dc. A few don't make it due to iframes which confound Fathom's capture tools, but the rest all succeed--and now improve the ML model as well as acting as tests. The training results after said integration reflect this improvement, which boosts testing precision and recall for every type.
* Add a mochitest to ensure the Fathom integration code can surface a decision that a field should not be autofilled. Decisions that go the other way are taken care of by the existing autofill tests.
Differential Revision: https://phabricator.services.mozilla.com/D100141
Get a version which will throw a specific error when isVisible() is run on elements that aren't in a window.
Some of the xpcshell tests crash because they transit through the codepath that calls Fathom, even though they don't do anything with its output. Fathom gets cranky and throws an exception because the elements it's evaluating don't live within a window object (an artifact of the test harness). This lets us swallow that exception and no others.
Differential Revision: https://phabricator.services.mozilla.com/D107906
Implement an observer to wait for correct window events in order to restore tab
content. Non-SHIP code restores about:reader scroll position after receiving
"AboutReaderContentReady" event, so to achieve the same thing with session
history in parent enabled, we can wait for "AboutReader:Ready" event.
Differential Revision: https://phabricator.services.mozilla.com/D108712