Add test cases for `DecoderDoctorDiagnostics::StoreFormatDiagnostics()`, which is used when checking the ability of whether the decoder is supported for certain type.
Differential Revision: https://phabricator.services.mozilla.com/D104475
If some attributes are only able to be set in certain platform, that increase the difficulty of wrting a test.
Therefore, we make them being able to set in all platforms, but doing the check in the fianl stage, which is reporting the result, to ensure that those error would still only be displayed on the right platform.
But if we're in testing, then we can test all error types in one platform.
Differential Revision: https://phabricator.services.mozilla.com/D104474
Two reasons to have this patch,
(1) we should let caller to be responsible to set the error, like what we do for WMF decoder module. `DecoderDoctorDocumentWatcher` should simply relys on the flag set in `DecoderDoctorDiagnostics`.
(2) separating these two different error helps us write a test for different error situation, without relying on the actual state of ffmpeglinker.
Differential Revision: https://phabricator.services.mozilla.com/D104473
This operation is actually meaningless, because at the time we call `CreateRddPDMs()`, the PDMFactory is just created. [PDMFactory()->CreatePDMs()->CreateRddPDMs()]
So that is impossible that we've failed to load ffmpeg before, so no need to subtract the `FFmpegFailedToLoad` flag.
Differential Revision: https://phabricator.services.mozilla.com/D104472
`MediaPlatformDecoderNotFound` sounds too general and seems indicating that this error is platform independent, but that is not true. This error is actually for not founding ffmpeg.
Differential Revision: https://phabricator.services.mozilla.com/D104471
Depends on D106002
The goal is to reduce the usage of the getToolbox(target) API.
It feels like exposing toolbox on the connector should be a more straightforward way of achieving the same thing?
Differential Revision: https://phabricator.services.mozilla.com/D106032
Depends on D105999
This patch is mostly a mechanical rewrite of:
```lang=javascript
const target = await TargetFactory.forTab(tab);
const toolbox = await gDevTools.showToolbox(target, "inspector");
```
to
```lang=javascript
const toolbox = await gDevTools.showToolboxForTab(tab, { toolId: "inspector" });
```
The main changes are:
- if the target was actually used in the test, it is now retrieved from toolbox.target
- the arguments for showToolboxForTab are using an option argument, to avoid the occasional showToolbox("inspector", null, null, null, startTime, null, reason);
I suspect that any signature rewrite mistake would have been caught on try.
There a few less mechanical changes:
- devtools/client/framework/test/browser_toolbox_screenshot_tool.js the toolId "console" was omitted because this id doesn't match any tool (author probably meant "webconsole")
- a few tests were: 1/ first creating a target, 2/ looping on tool definitions to get supported tools 3/ opening the toolbox with each supported tool. To support this I extracted a helper called `getSupportedToolIds` which opens a temporary toolbox to list all supported tool ids
- all the tests under storage/ use a single helper to start the test, which can open toolboxes for both tab targets and other targets. This made it more complicated to refactor. We could also drop this part and just refactor each test when we actually modify forTab/showToolbox to only work with descriptors
All in all the goal of this stack is to pave the way to stop handling targets when using forTab/showToolbox, and behind the scenes stop replying on targets to cache open toolboxes. We don't aim to kill all the call sites, just get them to a smaller number so that the next refactors will be easier.
Differential Revision: https://phabricator.services.mozilla.com/D106000
Depends on D105740
WPT runner can target several older versions of Firefox, so only use the new showToolboxForTab when the API is available on DevToolsShim
Differential Revision: https://phabricator.services.mozilla.com/D105743
The webplatform test runner recently added an option to open devtools during their tests.
The current implementation relies on TargetFactory::forTab and gDevTools::showToolbox.
Those methods will most likely change as we move away from targets and start using descriptors.
See previous WPT PR at https://github.com/web-platform-tests/wpt/pull/27309
Differential Revision: https://phabricator.services.mozilla.com/D105740
This removes the last bit of unsafety from iccread.rs.
It also removes the now unused 'be' types and conversion
functions.
Differential Revision: https://phabricator.services.mozilla.com/D106469
With Bug 1688813 drawSnapshot will handle fixed element, so we don't have to do
it from DevTools code.
We can remove this._lastScrollPosition in the screenshotContentActor, which means
we can also get rid of captureDone, which was only used to set the original scroll
position back.
Differential Revision: https://phabricator.services.mozilla.com/D106065
On 32-bit Windows, we see crashes related to running out of virtual
memory address space in the GPU process. Prior to this patch, we did not
report any memory status information from the GPU process to the parent,
only from the parent to the GPU process. Now if we go below the
threshold we request memory to be cleared in the parent/content
processes. This should trickle down to the GPU process by freeing shared
memory resources such as images, allowing us to unmap them out of the
GPU process sooner.
We will see similar problems on any 32-bit platform. The only other
target of note with sufficient numbers is 32-bit Android. There is no
GPU process on Android, however we only monitor the virtual memory
address space on Windows.
Differential Revision: https://phabricator.services.mozilla.com/D106286
This also adds related DLLs to be delay loaded to xul's moz.build. This means
that if we don't create the devices they are not loaded at all.
Differential Revision: https://phabricator.services.mozilla.com/D105630
Abspos boxes resolve against the pading box, and we were failing to
increase the percentage basis in that case if box-sizing was
content-box.
This is partially the cause of bug 1691374.
Differential Revision: https://phabricator.services.mozilla.com/D104389
Combine implementation of:
- NativeLookupPropertyInline
- LookupPropertyPure
Instead of checking for `is<NativeObject>`, check for a lookupProperty hook
which is more indicative of what we are worried about.
Differential Revision: https://phabricator.services.mozilla.com/D106240
Merge the following implementations:
- NativeLookupOwnPropertyInline
- NativeLookupOwnPropertyNoResolve
- LookupOwnPropertyPure
Use templates to differential different handling of resolve hooks. This tries
to maintain most of the existing nuance to avoid changing too much at once.
We no longer support anything with a lookupProperty hook. Previously the JITs
would tolerate them, but in practice do nothing useful. One case was for
environment objects which triggered this during SetProp but would later
abort. The other case was TypedObjects which are no longer meaningully
supported by the JITs and are treated no differently than unknown.
Differential Revision: https://phabricator.services.mozilla.com/D106239
On macos re-showing it without using `hidden` can cause, apparently,
extra popuphidden events. Let's do the right thing and close the popup
properly using hidePopup().
This code wasn't being hit before bug 1339380 because we relied on the
parent side to hide it, which did correctly fire the events.
Differential Revision: https://phabricator.services.mozilla.com/D106431
This fixes a number of problems:
1. The check around get_rgb_colorants was inverted. This caused us to
only continue if the colorants were wrong.
2. get_rgb_colorants can just return the Matrix instead of taking
a reference to it.
3. No tests
Differential Revision: https://phabricator.services.mozilla.com/D106463
Depends on D106002
The goal is to reduce the usage of the getToolbox(target) API.
It feels like exposing toolbox on the connector should be a more straightforward way of achieving the same thing?
Differential Revision: https://phabricator.services.mozilla.com/D106032