RecordedEvent::EventType::INVALID should never be seen in a recording
and so can be used as a sentinel value that we can assert against. If it
is seen, then the recording should fail gracefully.
Differential Revision: https://phabricator.services.mozilla.com/D198649
Porting only the main thread checks but not the checks inside service workers, because it's not clear what to do with permissions there as testdriver.js is window specific. Maybe it can be tweaked for service worker compatibility, but not in this patch.
Differential Revision: https://phabricator.services.mozilla.com/D196181
Ideally this validation steps should be shared in PushManager::Subscribe, but that's out of scope for this bug. For now this just copypastes the step from `dom/push/PushService.sys.mjs`.
Differential Revision: https://phabricator.services.mozilla.com/D196586
If given `nsPresContext` is for a lazy loading `<iframe>` and the frame has not
been loaded yet, its `GetTextInputHandlingWidget()` may return `nullptr`.
However, `IMEStateManager::sTextInputHandlingWidget` may have already cache it.
Therefore, `IMEStateManager` should use:
* `sTextInputHandlingWidget` if it's available
* otherwise, `nsPresContext::GetTextInputHandlingWidget()`
Differential Revision: https://phabricator.services.mozilla.com/D197991
to remove unnecessary deinterleaving.
This will facilitating passing the output for a secondary output device,
without interleaving.
The AudioChunk is down-mixed directly into the AudioProcessing's input buffer,
rather than using an AudioPacketizer, to skip another one or two copies.
processedFrameCount accounting in TestAudioCallbackDriver.SlowStart is
adjusted to ignore frames processed while waiting for the fallback driver to
stop [1] and to continue counting frames while the driver shuts down.
[1]
https://searchfox.org/mozilla-central/rev/6856d0cab9e37dd9eb305f174ff71f0a95b31f82/dom/media/GraphDriver.cpp#873-882
Depends on D198236
Differential Revision: https://phabricator.services.mozilla.com/D198237
The new behavior is better than the traditional behavior -- considering with
the default style of HTML -- especially when an element is an unknown element or
a custom element.
We've fixed a lot of assertion failures of this change and we have no serious
remaining issues now. Therefore, I think that we can ship it in all channels.
Differential Revision: https://phabricator.services.mozilla.com/D198245
The primary motivation for MediaStreamRenderer keeping track of and settling
incomplete promises is that, after changes in subsequent patches,
AudioStreamTrack outputs will share CrossGraphReceivers and so dedicated
CrossGraphReceivers will no longer be available to reject incomplete promises
when CrossGraphRecievers are Destroy()ed when an output is removed.
This also reliably keeps promise resolution in order wrt the synchronous
resolution from a setSinkId() call while playback is paused.
When a promise is settled because a subsequent pause or setSinkId() makes
the device change unnecessary, the promise is now resolved instead of
rejected. The new behavior is consistent with the resolution of a
promise created while playback is paused and with AudioSinkWrapper. Promise
resolution may be less likely to surprise content script than promise
rejection.
The situation with multiple tracks is somewhat arbitrary. Settling of the
promise depends on which tracks were present when setSinkId() was called.
GenericPromise::All() in MediaStreamRenderer::SetAudioOutputDevice() would
reject when the first track that existed at setSinkId() was removed or ended.
This patch switches to AllSettled() and resolves when all tracks that existed
at setSinkId() have ended. When AudioStreamTrack outputs no longer have
dedicated CrossGraphRecievers, removal of tracks will no longer cause the
promise to be settled until no tracks require the device.
Differential Revision: https://phabricator.services.mozilla.com/D198231
The MediaTrackGraphImpl is used directly rather than obtained from the
MediaTrack because the MediaTrack will be removed in D198232.
Differential Revision: https://phabricator.services.mozilla.com/D198230
There is no need to build Zip.cpp anymore when the linker is not
enabled, because nsGeckoUtils.cpp doesn't actually use it anymore.
Differential Revision: https://phabricator.services.mozilla.com/D198349
Porting only the main thread checks but not the checks inside service workers, because it's not clear what to do with permissions there as testdriver.js is window specific. Maybe it can be tweaked for service worker compatibility, but not in this patch.
Differential Revision: https://phabricator.services.mozilla.com/D196181
Ideally this validation steps should be shared in PushManager::Subscribe, but that's out of scope for this bug. For now this just copypastes the step from `dom/push/PushService.sys.mjs`.
Differential Revision: https://phabricator.services.mozilla.com/D196586
To reproduce the issue with the specific message bar:
1. quit/restart your local build of Firefox to ensure you have some session data
2. set the `browser.startup.couldRestoreSession.count` pref to 1
3. run this snippet in the browser toolbox:
```js
Cc["@mozilla.org/browser/browserglue;1"].getService(Ci.nsISupports).wrappedJSObject._maybeShowRestoreSessionInfoBar();
```
As @dholbert mentioned in the bug this is a band-aid fix. Seems alright though given the `.footer-button` class is just a hack to provide in-content button styles in the chrome. Long term we want to remove it in favour of unified button styles and/or the `moz-button` component (see Bug 1858814).
Differential Revision: https://phabricator.services.mozilla.com/D198589
Since most draw commands in a recording reference the same DrawTarget
over and over again, it saves a lot of space in the recording buffer to
create a dedicated RecordedSetCurrentDrawTarget command which caches the
current DrawTarget pointer and each subsequent command that needs a
DrawTarget will use the current.
Differential Revision: https://phabricator.services.mozilla.com/D198310
The current behavior doesn't make sense anyway because the permission request is denied anyway by the time the prompt happens.
Differential Revision: https://phabricator.services.mozilla.com/D198391
This probably needs to wait for that PR to be merged since unlike the
range tests, these actually test the clip value.
Depends on D197456
Differential Revision: https://phabricator.services.mozilla.com/D197457
This is preferable behavior. Otherwise the behavior changes with
and without scrolling enabled, which is rather weird.
Depends on D198395
Differential Revision: https://phabricator.services.mozilla.com/D198396
These flags are generally always set simultaneously via
NS_BLOCK_FORMATTING_CONTEXT_STATE_BITS. This commit changes the three
remaining places where only NS_BLOCK_FLOAT_MGR is set:
1. nsFileControlFrame, used by <input type="file">
2. nsComboboxControlFrame used by <select>
3. nsSelectsAreaFrame, used by <select multiple>
(1) and (2) create their own child frames that can't be styled by
authors. (3) wraps its children into a -moz-scrolled-content which
already prevents them from taking collapsing margins with their parent.
So it is safe to add NS_BLOCK_MARGIN_ROOT here.
Differential Revision: https://phabricator.services.mozilla.com/D198523