Граф коммитов

30111 Коммитов

Автор SHA1 Сообщение Дата
Jens Stutte cbf1df6c09 Bug 1763893: Avoid late creation of the GPU process. r=aosmond
The GPU process is destroyed in `ShutdownPhase::XPCOMShutdown` thus we shall not try to create it if we are in or beyond that phase.
Actually we might want to consider to block the creation even earlier if it does not exist, maybe from `ShutdownPhase::AppShutdown`, but this patch wants to just repair the crashes.

Differential Revision: https://phabricator.services.mozilla.com/D143349
2022-04-11 11:49:21 +00:00
Emilio Cobos Álvarez 18b32b3f08 Bug 1763184 - Fix -Wunused in non-wayland builds.
MANUAL PUSH: Trivial tier 2 build fix.
2022-04-08 17:31:13 +02:00
Jeff Muizelaar 3a84a85318 Bug 1763818 - Add a failure reason string for driver version mismatch. r=aosmond
Differential Revision: https://phabricator.services.mozilla.com/D143272
2022-04-08 15:13:05 +00:00
Emilio Cobos Álvarez 548997b639 Bug 1763184 - Remove unreachable special-case in ScreenGetterGTK. r=stransky
Gnome on Wayland uses ScreenGetterWayland, so the special-case can be
removed.

Depends on D142963

Differential Revision: https://phabricator.services.mozilla.com/D142964
2022-04-08 13:28:07 +00:00
Emilio Cobos Álvarez a4d47cfd00 Bug 1756903 - Consider using client decorations everywhere. r=stransky
I tested client all the way back to Ubuntu 18 LTS and seems to work
fine, any reason not to try this?

This fixes some weird overdrawing on the window corners on GNOME+X11.

Differential Revision: https://phabricator.services.mozilla.com/D139556
2022-04-08 13:19:52 +00:00
Emilio Cobos Álvarez 0d0ad9c7f3 Bug 1763746 - Stop preferring dark background for SelectedItem/SelectedItemText. r=stransky
This was added because ElementaryOS themes have bright selected
backgrounds and dark text (for light themes), but we use the accent
colors for some places where that is not appropriate and a darker color
is, like checkbox backgrounds or form control borders.

Bug 1741293 split the selected item text / background colors from the
accent colors, so now we can use the real selected item colors and only
do this on the accent color. I wanted to split this out from bug 1741293
to minimize behavior changes in there.

Also while at it, blend opaque foreground with the appropriate
background on EnsureColorPairIsOpaque.

Differential Revision: https://phabricator.services.mozilla.com/D143255
2022-04-08 06:51:15 +00:00
Jeff Muizelaar cc87888919 Bug 1762125. Allow DXVA on newer Intel drivers. r=alwu
Newer Intel drivers break our assumptions about the bottom four digits
being the build id and we end up blocking newer drivers with build ids
like 11404. This reverts the change in bug 1295902 which changed this
blocklist rule to only look at the build number. I think bug 1295902 was
just trying to be more correct and I don't know that it actually blocks
important crashes. Decoding now mostly happens in the GPU process
so the impact of these crashes is reduced from what it originally was.

The information on how to interpret Intel driver version is from:
https://www.intel.ca/content/www/ca/en/support/articles/000005654/graphics.html

The proper fix is to have Intel specific driver version parsing.

Differential Revision: https://phabricator.services.mozilla.com/D143248
2022-04-08 01:41:01 +00:00
Emilio Cobos Álvarez ff12c3d22c Bug 1763679 - Null-check in PrintTargetPDF, rather than relying on the caller to do so. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D143245
2022-04-08 01:00:32 +00:00
Shazib Summar 20cb0cdcb7 Bug 1617283 - Shifted AudioSession to MTA and removed COM violations r=handyman
Cleans up the interface to AudioSession and brings in line with COM best practices.  Uses background threads that are implicitly MTA and asserts proper thread behavior.  This also removes AudioSession's Co[Un]Initialize static analysis violations.

Differential Revision: https://phabricator.services.mozilla.com/D140741
2022-04-07 18:39:49 +00:00
sotaro c24f60bb9d Bug 1763280 - Enable avoid copying hardware decoded video on intel GPU on Window on nightly r=jrmuizel,gfx-reviewers
Blocked intel drivers are from chromium's "disable_dxgi_zero_copy_video" in gpu_driver_bug_list.json

Differential Revision: https://phabricator.services.mozilla.com/D143017
2022-04-07 14:38:17 +00:00
stransky 0024e9426e Bug 1761870 [Wayland] Mark MozContainer as mapped to make sure moz_container_wayland_unmap() is called on hide/withdraw r=emilio
Depends on D143168

Differential Revision: https://phabricator.services.mozilla.com/D143169
2022-04-07 13:20:07 +00:00
stransky 2e6ccbec80 Bug 1761870 [Wayland] Clear button press count on D&D workaround if D&D is finished r=emilio
Depends on D143167

Differential Revision: https://phabricator.services.mozilla.com/D143168
2022-04-07 13:20:06 +00:00
stransky 9ca8cec9f5 Bug 1761870 [Wayland] Don't assert if there's active draw callback after unmap event r=emilio
It's possible that moz_container_wayland_frame_callback_handler() is called after unmap event if we draw to parent surface so don't assert there.

Differential Revision: https://phabricator.services.mozilla.com/D143167
2022-04-07 13:20:06 +00:00
Jamie Nicol cee8f98714 Bug 1763392 - Generate SDK bindings for nested Java classes as nested C++ classes. r=agi,media-playback-reviewers,bryce
For example, the SDK class android.media.MediaDrm$KeyStatus will now
be defined as MediaDrm::KeyStatus rather than just KeyStatus.

Not only does this avoid polluting the top-level namespace, but it
also avoids a bug where invalid type names were generated if the
nested class contains a method with a parameter or return of the outer
class' type.

Differential Revision: https://phabricator.services.mozilla.com/D143043
2022-04-07 11:12:20 +00:00
Emilio Cobos Álvarez a9620e05aa Bug 1763591 - Clean up a bit nsWaylandDisplay. r=stransky
Use inline initializers and remove (void), which is not necessary in
C++.

Differential Revision: https://phabricator.services.mozilla.com/D143147
2022-04-07 11:10:31 +00:00
Emilio Cobos Álvarez 7cc5a5cf03 Bug 1741293 - Make Adwaita dark accent color the same as Adwaita light. r=stransky
GTK3 doesn't have accent colors per se so we reuse the "selected item"
colors.

However, GTK4 does, and dark and light accent colors in libadwaita are
the same, so special-case Adwaita to copy the colors from the light
theme.

Differential Revision: https://phabricator.services.mozilla.com/D143064
2022-04-07 11:06:26 +00:00
Masayuki Nakano 91e18f14d8 Bug 1760160 - Make `ContentCacheInChild` stop storing content if editable element has already been blurred r=m_kato
It's designed for caching content information of focused editor.  However, at
sending focus notification to the main process, the editor may have already
been blurred but `IMEContentObserver` may have not known it yet.  In this edge
case, only query selection succeeds since IMEContentObserver still has a cache,
but query the others failed because of root content node check of
`IMEContentObserver::HandleQueryContentEvent`.  If a content process meets this
case, it should not send focus notification and stop storing the content since
IME shouldn't get focus nor query non-editable content.

On the other hand, the reported testcase reproduces this with a fuzzing API
called **in** the content process. Therefore, I have no idea how to reproduce
it without the API. That's the reason why this patch does not contain new tests.

Differential Revision: https://phabricator.services.mozilla.com/D141821
2022-04-07 00:58:49 +00:00
Stephen A Pohl 1cbc5fe496 Bug 1684739: Only check if swipe tracking is enabled on macOS if the event is a scrollwheel event. r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D142328
2022-04-06 17:46:41 +00:00
Emilio Cobos Álvarez b8f1a27f5a Bug 1761923 - Make some shadow colors react to dark mode in GTK/Cocoa. r=mstange
This matches Windows' behavior.

Differential Revision: https://phabricator.services.mozilla.com/D142319
2022-04-06 17:16:41 +00:00
Emilio Cobos Álvarez 1c85d9751f Bug 1763410 - Add dark color scheme support for accent color in non-native theme. r=mstange
We added dark form control support a while ago but missed this.

Differential Revision: https://phabricator.services.mozilla.com/D143059
2022-04-06 15:54:55 +00:00
Emilio Cobos Álvarez 09940843a8 Bug 1763184 - Clean-up some GTK screen code. r=stransky
Clean up logging and remove some useless namespacing.

Differential Revision: https://phabricator.services.mozilla.com/D142963
2022-04-06 10:08:58 +00:00
Timothy Nikkel cf44ee875e Bug 1757928. Add test. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D142817
2022-04-06 09:51:17 +00:00
Timothy Nikkel a70b5ad77a Bug 1757928. Make the swipe events sent by SwipeTracker have the same scale. r=hiro
Bug 1753146 doubled the success threshold for Windows only, but browser/base/content/browser-gestureSupport.js at https://searchfox.org/mozilla-central/rev/26a1b0fce12e6dd495a954c542bb1e7bd6e0d548/browser/base/content/browser-gestureSupport.js#739 multiplies the values present in swipe events by 4 to determine opacity; so it it assuming the value 0.25 is the success threshold.

This patch first reverts bug 1753146 and then fixes it in a different way, so that the success threshold still has the same value and hence we don't need to modify browser-gestureSupport.js (so that all the code depending on this is in one one). We double the kWholePagePixelSize on Windows (and turn it into a pref) so that we don't regress bug 1753146. This is equivalent because the numeric value computed in SwipeTracker::ComputeSwipeSuccess will be the same, since the values mGestureAmount and mCurrentVelocity all have a division by kWholePagePixelSize when they are computed in SwipeTracker::ProcessEvent. There is one difference though: the velocity twitch tolerance comparison in SwipeTracker::ComputeSwipeSuccess will be slightly different. I think that's okay though.

Differential Revision: https://phabricator.services.mozilla.com/D140185
2022-04-06 09:51:17 +00:00
Alexandre Lissy fc60003485 Bug 1762867 - Update correct wayland MonitorConfig r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D142934
2022-04-06 08:44:34 +00:00
Bryce Seager van Dyk 14c08205a6 Bug 1762521 - Add further locking to JumpListBuilder. r=mhowell,jesup
This fixes two cases where thread safety analysis complains about us not holding
the monitor.

Differential Revision: https://phabricator.services.mozilla.com/D142775
2022-04-06 01:18:42 +00:00
Timothy Nikkel 4cac1c7814 Bug 1763121. nsIDOMWindowUtils::sendNativeTouchpadPan should use an observer to notify when the event has been sent to the destination widget. r=hiro
Otherwise we can return without the widget even seeing the event. This is how other test functions are implemented.

We need this to make the test in bug 1757928 pass.

Differential Revision: https://phabricator.services.mozilla.com/D142943
2022-04-05 22:53:35 +00:00
Stephen A Pohl 7bdcd75fb9 Bug 1742877: Add the proper window mask to borderless windows on macOS that are expected to be miniaturizable, such as the screen share indicator. r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D142962
2022-04-05 16:24:34 +00:00
Jonathan Watt b876849eb8 Bug 1668210. Prevent print settings being saved to unprefixed prefs on non-Android. r=bobowen
Differential Revision: https://phabricator.services.mozilla.com/D91907
2022-04-04 19:42:35 +00:00
Marian-Vasile Laza 5d488b5106 Backed out changeset 865d5128459a (bug 1761923) for causing reftest and xpcshell failures. CLOSED TREE 2022-04-04 13:50:47 -07:00
Emilio Cobos Álvarez a18fdda05d Bug 1762298 - GCC build bustage and reftest fixes.
MANUAL PUSH: Orange fix CLOSED TREE
2022-04-04 22:14:24 +02:00
Emilio Cobos Álvarez cae6641413 Bug 1761923 - Add generic Buttonshadow support.
MANUAL PUSH: Fixes orange CLOSED TREE
2022-04-04 22:00:28 +02:00
Emilio Cobos Álvarez c3844882b4 Bug 1761923 - Make some shadow colors react to dark mode in GTK/Cocoa. r=mstange
This matches Windows' behavior.

Differential Revision: https://phabricator.services.mozilla.com/D142319
2022-04-04 18:21:00 +00:00
Emilio Cobos Álvarez ea091cc7c2 Bug 1762152 - Don't propagate changes from layout back to layout. r=stransky
When not using move-to-rect we're not making decisions on positioning,
and thus layout should already be aware of the correct bounds. There
should be no need to propagate the extra changes.

This would've fixed the issue as well (for non-flipped popups, that is),
but the previous patch is still a requirement for flipped popups.

Differential Revision: https://phabricator.services.mozilla.com/D142680
2022-04-01 13:51:35 +00:00
Emilio Cobos Álvarez 4111acc9b7 Bug 1630251 - Ignore window move request when not in the normal size mode. r=stransky
This should help.

Differential Revision: https://phabricator.services.mozilla.com/D142672
2022-04-01 11:23:55 +00:00
Emilio Cobos Álvarez e47024038c Bug 1762018 - Derive a color scheme when forcing preference colors. r=morgan
This patch is a bit bigger than I'd like, but it's mostly moving code
around to centralize the color/color-scheme decisions we make when
forcing colors.

In practice, the only behavior change should be that when "use system
colors" is false and we force colors, we force a color-scheme that
matches the user-chosen background (via the LookAndFeel::IsDarkColor
check).

That should make sure that text from system colors is light and matches
the user expectations.

Before this patch, we used to force the color-scheme to light, but that
was just so that we ended up looking at mLightColors. Instead, we
achieve that via a separate bit (mForcedLightColorSet, naming up for
debate, not a fan), so that we can use the right system colors
otherwise.

Another alternative I considered is making all non-link system colors
return mDefaultBackground / mDefault depending on whether they are
background / foreground colors. That seemed a lot more work and
potentially a regression in various ways. I think this should be
strictly an improvement instead.

Differential Revision: https://phabricator.services.mozilla.com/D142423
2022-04-01 01:21:22 +00:00
Cristian Tuns da85cd4a66 Backed out changeset 5d97c7b1b9b5 (bug 1762018) for causing mochitest failures in test_bug232227.html CLOSED TREE 2022-03-31 19:12:48 -04:00
Emilio Cobos Álvarez 0555de1ae2 Bug 1762018 - Derive a color scheme when forcing preference colors. r=morgan
This patch is a bit bigger than I'd like, but it's mostly moving code
around to centralize the color/color-scheme decisions we make when
forcing colors.

In practice, the only behavior change should be that when "use system
colors" is false and we force colors, we force a color-scheme that
matches the user-chosen background (via the LookAndFeel::IsDarkColor
check).

That should make sure that text from system colors is light and matches
the user expectations.

Before this patch, we used to force the color-scheme to light, but that
was just so that we ended up looking at mLightColors. Instead, we
achieve that via a separate bit (mForcedLightColorSet, naming up for
debate, not a fan), so that we can use the right system colors
otherwise.

Another alternative I considered is making all non-link system colors
return mDefaultBackground / mDefault depending on whether they are
background / foreground colors. That seemed a lot more work and
potentially a regression in various ways. I think this should be
strictly an improvement instead.

Differential Revision: https://phabricator.services.mozilla.com/D142423
2022-03-31 22:03:09 +00:00
Emilio Cobos Álvarez 7e23a4287f Bug 1760836 - Support printing to an nsIOutputStream. r=jfkthame,jrmuizel,webdriver-reviewers,geckoview-reviewers,agi
The trickiest bits are the PrintTargetCG ones, the rest is just plumbing
and cleanups and tests, but let me know if you want those to be split
out, can do.

The GTK change to nsPrintSettingsGTK::GetResolution is a no-op (we only
read resolution on windows), but I did that because we assume that it
doesn't fail and GTK returns a sane default anyways.

Differential Revision: https://phabricator.services.mozilla.com/D142199
2022-03-30 18:51:58 +00:00
alwu 532502a58c Bug 1762206 - revert incorrect removal in bug 1761332. r=gfx-reviewers,jrmuizel
This was a mistake, which should not be removed.

Differential Revision: https://phabricator.services.mozilla.com/D142475
2022-03-30 17:53:20 +00:00
Jamie Nicol dbde42a288 Bug 1762025 - Block GPU process on Android versions 12 and above. r=gfx-reviewers,aosmond
On Android version 12, it appears as if the EGL context does not
correctly get detached from a Surface when its process dies. This
means that subsequent attempts to create an EGL context fail, meaning
we cannot render anything.

This results in a completely unusable browser following a GPU process
crash, which is worse than the alternative of a parent process crash.

Block the GPU process on Android 12 and above until we have found a
workaround.

Differential Revision: https://phabricator.services.mozilla.com/D142452
2022-03-30 13:37:19 +00:00
alwu 8958aa15a8 Bug 1761332 - block all Haswell devices and a certain version of intel driver for VP8 hw decoding. r=jrmuizel
This is a follow-up for bug1760464, we observed more crashes from devices which we didn't added to the block list before.

Therefore, we decided to block all Haswell GPUs for VP8 HW decoding (Intel supports that sine Broadwell) and a certain version of Intel driver.

Differential Revision: https://phabricator.services.mozilla.com/D142360
2022-03-29 20:30:23 +00:00
Iulian Moraru 7a3ed2ce2a Backed out changeset d42d7505c9cf (bug 1760836) for causing mochitest failures on browser_print_stream.js. CLOSED TREE 2022-03-29 23:32:39 +03:00
Emilio Cobos Álvarez b0fb172236 Bug 1760836 - Support printing to an nsIOutputStream. r=jfkthame,jrmuizel,webdriver-reviewers,geckoview-reviewers,agi
The trickiest bits are the PrintTargetCG ones, the rest is just plumbing
and cleanups and tests, but let me know if you want those to be split
out, can do.

The GTK change to nsPrintSettingsGTK::GetResolution is a no-op (we only
read resolution on windows), but I did that because we assume that it
doesn't fail and GTK returns a sane default anyways.

Differential Revision: https://phabricator.services.mozilla.com/D142199
2022-03-29 17:50:58 +00:00
sotaro a85bae612a Bug 1760724 - Let video overlay ride the trains to release on intel GPU on Windows r=gfx-reviewers,lsalzman
pref gfx.webrender.dcomp-video-overlay-win-force-enabled was added to enable video overlay even when it is blocked.

Differential Revision: https://phabricator.services.mozilla.com/D141712
2022-03-29 02:47:18 +00:00
stransky 9cac822f97 Bug 1761435 [Wayland] Store only move-to-rect popup size r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D142048
2022-03-28 10:13:40 +00:00
Makoto Kato 9f9179d4e9 Bug 1761176 - Set insertion marker location for IME. r=geckoview-reviewers,agi
When using Android with physical keyboard, IME's candidate window is sometimes
misplaced. Some IME/keyboards require insertion marker location to set IME's
candidate window position.

So we should set it from caret rectangle.

Differential Revision: https://phabricator.services.mozilla.com/D141931
2022-03-28 05:29:21 +00:00
Emilio Cobos Álvarez b554ad2947 Bug 1761663 - Fix --disable-dbus build.
MANUAL PUSH: Trivial non-default build configuration fix.
2022-03-27 17:06:03 +02:00
Gian-Carlo Pascutto 0bd9035ceb Bug 1761509 - Fix missing include that MinGW requires. r=sylvestre
Differential Revision: https://phabricator.services.mozilla.com/D142102
2022-03-25 22:20:42 +00:00
Emilio Cobos Álvarez 7fc2a16eac Bug 1761408 - Ensure Windows cursor is up-to-date from nsWindow::SetCursor(). r=mhowell
Also add better docs as to why we're doing what we're doing.

Also, avoid calling LoadCursor for built-in cursors over and over in chrome
pages.

Differential Revision: https://phabricator.services.mozilla.com/D142067
2022-03-25 17:59:22 +00:00
Max Vollmer d4159632e0 Bug 1751281 - Enable Windows Event logging with separate logging module and message parameters r=cmartin
Differential Revision: https://phabricator.services.mozilla.com/D141728
2022-03-25 15:27:39 +00:00
stransky 588b7423e7 Bug 1760276 [Wayland] Fix loop in popup move-to-rect resizes r=emilio
Use mMoveToRectPopupRect popup constrains in nsMenuPopupFrame::SetPopupPosition only and make it pernament.
In such setup works as screen size constraints.

Don't call SetPopupPosition from move-to-rect callback and let layout code to handle that.

Remove MoveToRectPopupRectClear() as it's not needed, we keep mMoveToRectPopupRect
in nsMenuPopupFrame as well as we keep screen sizes there.

Differential Revision: https://phabricator.services.mozilla.com/D141602
2022-03-25 11:15:39 +00:00
stransky 00c8402a07 Bug 1760276 [Wayland] Avoid to use move-to-rect when possible r=emilio
Due to move-to-rect limitations (https://gitlab.gnome.org/GNOME/gtk/-/issues/1986) we try to avoid it when it's possible.

- Use plain popup resize/movement when popup is places inside of application toplevel window.
- Hide moved/scaled popup window only when move-to-rect is used.
- Clear mMoveToRectPopupRect before any move/resize and use Wayland compositor to place/size the window.

Differential Revision: https://phabricator.services.mozilla.com/D141601
2022-03-25 11:15:38 +00:00
stransky 044026434a Bug 1760276 [Wayland] When we check for popup resize workaround, consider toplevel window instead of parent one, r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D141600
2022-03-25 11:15:38 +00:00
Norisz Fay d29d98d869 Backed out 3 changesets (bug 1760276) for causing build bustages on nsMenuPopupFrame.cpp CLOSED TREE
Backed out changeset e98dce4c58db (bug 1760276)
Backed out changeset 3d351d90db7b (bug 1760276)
Backed out changeset e8e0571ab13b (bug 1760276)
2022-03-25 12:02:18 +02:00
stransky 0226068db9 Bug 1760276 [Wayland] Fix loop in popup move-to-rect resizes r=emilio
Use mMoveToRectPopupRect popup constrains in nsMenuPopupFrame::SetPopupPosition only and make it pernament.
In such setup works as screen size constraints.

Don't call SetPopupPosition from move-to-rect callback and let layout code to handle that.

Remove MoveToRectPopupRectClear() as it's not needed, we keep mMoveToRectPopupRect
in nsMenuPopupFrame as well as we keep screen sizes there.

Differential Revision: https://phabricator.services.mozilla.com/D141602
2022-03-25 09:33:18 +00:00
stransky 8eca77b9dc Bug 1760276 [Wayland] Avoid to use move-to-rect when possible r=emilio
Due to move-to-rect limitations (https://gitlab.gnome.org/GNOME/gtk/-/issues/1986) we try to avoid it when it's possible.

- Use plain popup resize/movement when popup is places inside of application toplevel window.
- Hide moved/scaled popup window only when move-to-rect is used.
- Clear mMoveToRectPopupRect before any move/resize and use Wayland compositor to place/size the window.

Differential Revision: https://phabricator.services.mozilla.com/D141601
2022-03-25 09:33:18 +00:00
stransky ba683562a8 Bug 1760276 [Wayland] When we check for popup resize workaround, consider toplevel window instead of parent one, r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D141600
2022-03-25 09:33:18 +00:00
Brad Werth ac55f07b1b Bug 1751217 Part 4: Make macOS declare video-dynamic-range: high with new-enough OS. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D141056
2022-03-24 18:19:50 +00:00
Brad Werth 37d4a36187 Bug 1751217 Part 3: Make HDR-capable macOS screens report 30 pixelDepth. r=mstange
This matches Chrome behavior. Our video-dynamic-range media query also relies
on this value being greater than 24 in order to report "high" level support.

Differential Revision: https://phabricator.services.mozilla.com/D141306
2022-03-24 18:19:50 +00:00
stransky 7faf5c7a64 Bug 1757568 [Wayland] Always clear wayland frame callback in moz_container_wayland_frame_callback_handler() r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D141936
2022-03-24 10:38:26 +00:00
criss 0077f22487 Merge autoland to mozilla-central. a=merge 2022-03-24 11:35:23 +02:00
alwu c572486947 Bug 1760464 - block certain Intel graphic cards to prevent crashes while using Intel MFT for HW VP8 decoding. r=media-playback-reviewers,gfx-reviewers,bryce,aosmond
Differential Revision: https://phabricator.services.mozilla.com/D141810
2022-03-23 23:29:43 +00:00
Emilio Cobos Álvarez 90528b59b3 Bug 1761083 - Add a missing include.
MANUAL PUSH: Trivial Tier2 bustage fix CLOSED TREE
2022-03-23 21:36:31 +01:00
Butkovits Atila fbd6ad4819 Backed out 5 changesets (bug 1751217) for causing failures at dynamic-range.html. CLOSED TREE
Backed out changeset f0a4879c9709 (bug 1751217)
Backed out changeset 50b6310935d4 (bug 1751217)
Backed out changeset bfa455b8bb1a (bug 1751217)
Backed out changeset 277064a1facb (bug 1751217)
Backed out changeset 21e1650b12db (bug 1751217)
2022-03-23 22:22:54 +02:00
Andrew Osmond 3df496f168 Bug 1760887 - Expose FEATURE_VP8_HW_DECODE and FEATURE_VP9_HW_DECODE to the downloadable blocklist. r=gfx-reviewers,jnicol,media-playback-reviewers,alwu
This patch also exposes it as a gfxVar for cross process/thread-safe access.

Differential Revision: https://phabricator.services.mozilla.com/D141803
2022-03-23 19:28:57 +00:00
stransky 8245e73b53 Bug 1757568 [Wayland] Don't crash when MozContainer is unmapped in moz_container_wayland_frame_callback_handler r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D141842
2022-03-23 19:28:06 +00:00
Brad Werth c2a8cb2d17 Bug 1751217 Part 4: Make macOS declare video-dynamic-range: high with new-enough OS. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D141056
2022-03-23 18:23:01 +00:00
Brad Werth 1343f7c2b5 Bug 1751217 Part 3: Make HDR-capable macOS screens report 30 pixelDepth. r=mstange
This matches Chrome behavior. Our video-dynamic-range media query also relies
on this value being greater than 24 in order to report "high" level support.

Differential Revision: https://phabricator.services.mozilla.com/D141306
2022-03-23 18:23:01 +00:00
Emilio Cobos Álvarez b20aeffc46 Bug 1758357 - Don't call SetCursor redundantly on Windows. r=cmartin
Bug 1724120 apparently regressed this, which is a bit surprising because
the redundant ::SetCursor() call is already there. The real fix is the
one above, however I think this change is still worth it. Make cursor
updates avoid redundant ::SetCursor() calls the same way other widget
back-ends do (always except for mUpdateCursor, which is set on scale
changes and so on).

Differential Revision: https://phabricator.services.mozilla.com/D141864
2022-03-23 17:17:35 +00:00
Emilio Cobos Álvarez 79f3fe026d Bug 1759962 - Don't return the DPI override in devicePixelRatio to privileged code. r=nchevobbe,webdriver-reviewers
Chrome code should be able to rely on CSS pixel * devicePixelRatio =
device pixel.

Chrome code that cares about the override should use
BrowsingContext.overrideDPPX. We were exposing the no-override value in
WindowUtils but that's unneeded now.

Differential Revision: https://phabricator.services.mozilla.com/D141323
2022-03-23 17:03:04 +00:00
Emilio Cobos Álvarez 9ddc42292b Bug 1760839 - Use more automatic memory management in GTK code. r=stransky
This fixes a couple potential leaks (e.g., see the UPowerClient changes,
we weren't freeing all the devices properly).

Differential Revision: https://phabricator.services.mozilla.com/D141775
2022-03-23 16:14:34 +00:00
Marian-Vasile Laza 77029463ac Backed out 5 changesets (bug 1751217) for causing wpt(Screen-pixelDepth-Screen-colorDepth001.html) and mochitest(test_media_queries.html) failures. CLOSED TREE
Backed out changeset 60a4497fd1f5 (bug 1751217)
Backed out changeset 785f4c5f719d (bug 1751217)
Backed out changeset 81e41f7a1ee4 (bug 1751217)
Backed out changeset d35c5648c936 (bug 1751217)
Backed out changeset f16305c6ec83 (bug 1751217)
2022-03-23 10:11:53 -07:00
Emilio Cobos Álvarez 9f85342dbb Bug 1758357 - Fix PuppetWidget::SetCursor to avoid sending cursor updates to the parent process over and over. r=mstange
I accidentally regressed this in bug 1705877, so we'd always
force-update the cursor :(

Differential Revision: https://phabricator.services.mozilla.com/D141863
2022-03-23 15:31:02 +00:00
Brad Werth e2d894d2e2 Bug 1751217 Part 4: Make macOS declare video-dynamic-range: high with new-enough OS. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D141056
2022-03-23 15:24:39 +00:00
Brad Werth dd5793b3a4 Bug 1751217 Part 3: Make HDR-capable macOS screens report 30 pixelDepth. r=mstange
This matches Chrome behavior. Our video-dynamic-range media query also relies
on this value being greater than 24 in order to report "high" level support.

Differential Revision: https://phabricator.services.mozilla.com/D141306
2022-03-23 15:24:38 +00:00
smolnar b0d70eac11 Backed out changeset a891c506e692 (bug 1760887) for causing mda failures in test_autoplay_contentEditable. CLOSED TREE 2022-03-23 00:30:22 +02:00
Andrew Osmond 21e4a3df8a Bug 1760887 - Expose FEATURE_VP8_HW_DECODE and FEATURE_VP9_HW_DECODE to the downloadable blocklist. r=gfx-reviewers,jnicol
Differential Revision: https://phabricator.services.mozilla.com/D141803
2022-03-22 21:21:22 +00:00
Jamie Nicol d7be12a509 Bug 1760794 - Ensure default clear color gets set after compositor is (re)initialized. r=agi
In bug 1756700 we delayed initializing the compositor on android. A
consequence of this is that when
LayerViewSupport::SetDefaultClearColor() gets called
mUiCompositorControllerChild is still null, meaning we skip setting
the compositor's clear color. As a result, dark-mode fenix users have
once again started seeing white flashes while waiting for the page to
load.

Additionally, when the compositor is re-initialized (following a
fallback to software rendering, or a GPU process restart) we do not
set the clear color for the new compositor, which again can lead to
white flashes.

To fix both of these issues, this patch makes us cache the color value
passed to LayerViewSupport::SetDefaultClearColor(). Then whenever
LayerViewSupport::NotifyCompositorCreated() is called, we call
UiCompositorControllerChild::SetDefaultClearColor() to ensure the new
compositor uses the correct clear color.

Differential Revision: https://phabricator.services.mozilla.com/D141730
2022-03-22 21:05:30 +00:00
stransky 02c1890996 Bug 1760184 [Wayland] Apply correction for negative anchor width r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D141433
2022-03-22 20:51:22 +00:00
stransky 0a979b5726 Bug 1760179 [Wayland] Remove mUpdatedByMoveToRectCallback r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D141430
2022-03-22 20:23:11 +00:00
stransky f09ab65aa7 Bug 1760028 [Wayland] Remove mMoveToRectPopupRectCleared r=emilio
We don't need mMoveToRectPopupRectCleared field any more - we always calculate popup placement when a change comes from layout.

Differential Revision: https://phabricator.services.mozilla.com/D141429
2022-03-22 20:14:37 +00:00
stransky cb7a413574 Bug 1760028 [Wayland] Fix popup resize shortcut r=emilio
Take popup resize shortcut only when popup is placed inside parent window (check popup origin) and it's not moved by layout.
Fix gdk_window_get_width/gdk_window_get_height mismatch.

Differential Revision: https://phabricator.services.mozilla.com/D141428
2022-03-22 20:14:37 +00:00
stransky 19c39f9ec2 Bug 1760172 [Wayland] Rename PreferredPopupRect to MoveToRectPopupRect r=emilio
Rename PreferredPopupRect* methods/attributes to MoveToRectPopupRect* ones as it holds info about coordinates received from move-to-rect popup placement done by Wayland compositor.

Differential Revision: https://phabricator.services.mozilla.com/D141425
2022-03-22 20:04:54 +00:00
Iulian Moraru 6c42eedf49 Backed out changeset e560c3644632 (bug 1760794) for causing geckoview crashes. 2022-03-22 19:37:16 +02:00
Jamie Nicol 70fc3c717d Bug 1760794 - Ensure default clear color gets set after compositor is (re)initialized. r=agi
In bug 1756700 we delayed initializing the compositor on android. A
consequence of this is that when
LayerViewSupport::SetDefaultClearColor() gets called
mUiCompositorControllerChild is still null, meaning we skip setting
the compositor's clear color. As a result, dark-mode fenix users have
once again started seeing white flashes while waiting for the page to
load.

Additionally, when the compositor is re-initialized (following a
fallback to software rendering, or a GPU process restart) we do not
set the clear color for the new compositor, which again can lead to
white flashes.

To fix both of these issues, this patch makes us cache the color value
passed to LayerViewSupport::SetDefaultClearColor(). Then whenever
LayerViewSupport::NotifyCompositorCreated() is called, we call
UiCompositorControllerChild::SetDefaultClearColor() to ensure the new
compositor uses the correct clear color.

Differential Revision: https://phabricator.services.mozilla.com/D141730
2022-03-22 16:29:50 +00:00
Andrew Osmond 78afd0ab38 Bug 1760663 - Add blocklist support for WebGPU. r=gfx-reviewers,nical
This patch just adds the plumbing to allow for baked in blocklist rules
or the downloadable blocklist to prevent certain configurations from
getting WebGPU. It does not add any rules.

It also changes us from allowing WebGPU only in nightly, including
tests, to not release and not beta. This allows try to run the WebGPU
tests as expected, since even try builds forked from mozilla-central are
not considered nightly builds by CI (or so it seems).

Differential Revision: https://phabricator.services.mozilla.com/D141682
2022-03-22 15:22:39 +00:00
stransky 31e465fc89 Bug 1759157 [Wayland] Save layout popup setup on Wayland r=emilio
When a popup is only resized (and not moved), we need original move-to-rect setup from layout from previous popup placement to replicate move-to-rect call with updated size.
We can't get complete popup setup from layout for resize only event. It's because we use nsMenuPopupFrame::MoveTo() to place popup from move-to-rect callback (which happened before the resize event) and such direct popup move temporary change popup anchor type to point as we place popup to specified location from move-to-rect callback.

Differential Revision: https://phabricator.services.mozilla.com/D141424
2022-03-22 14:43:32 +00:00
Randell Jesup 4ae33c5413 Bug 1207753 - windows JumpListBuilder thread-safety annotations r=mhowell
Differential Revision: https://phabricator.services.mozilla.com/D141622
2022-03-21 17:56:56 +00:00
Emilio Cobos Álvarez c7570b5a64 Bug 1760316 - Add another Canon entry to the monochrome settings list. r=jwatt
Differential Revision: https://phabricator.services.mozilla.com/D141499
2022-03-19 16:48:25 +00:00
Masayuki Nakano 1b713219e4 Bug 1758420 - part 1: Let `TextComposition` know where is changed in storing text node r=m_kato
`IMEContentObserver` observes the text node change which contains the current
composition string.  Therefore, it can let `TextComposition` know where is
updated by web apps and adjust offset and length in the text node.

Differential Revision: https://phabricator.services.mozilla.com/D141193
2022-03-18 06:34:46 +00:00
Randell Jesup c5917ed65a Bug 1207753: Basic thread-safety annotations to quiet errors until real annotations land r=nika
Differential Revision: https://phabricator.services.mozilla.com/D141062
2022-03-17 18:39:15 +00:00
Emilio Cobos Álvarez b055f536ea Bug 1758702 - Allow ThreadSafeWeakPtr<IncompleteType> to work. r=glandium
This will be used to avoid problematic includes from WorkerPrivate.h,
and it matches the behavior of RefPtr<> and WeakPtr<>.

Differential Revision: https://phabricator.services.mozilla.com/D140658
2022-03-17 15:24:40 +00:00
Emilio Cobos Álvarez 5950d7b598 Bug 1736218 - Stop using heuristics to determine content color-scheme. r=dao
Use system color-scheme for content for anything that isn't explicitly
opted into.

Differential Revision: https://phabricator.services.mozilla.com/D140376
2022-03-17 14:44:04 +00:00
Emilio Cobos Álvarez 3d2bf29691 Bug 1750932 - Add color_scheme / content_color_scheme properties to theme API. r=robwu,dao
This allows themes to override our light / dark theme heuristics if they
choose to, so that we don't have to complicate the heuristics too much.

This is specially useful for themes with images, where the image might
be "light", but still have enough contrast with light text. A good
example is the theme mentioned in bug 1749837 comment 0.

The semantics are:

 * color_scheme: If set, overrides the general "toolbar theme" (so
   window and context menu appearance and so on), otherwise we fall back
   to heuristics.

 * content_color_scheme: If set, overrides the color scheme for the
   content area. Otherwise we fall back to color_scheme if present, or
   heuristics otherwise.

One thing that I didn't include was a sort of "system" option, which
might be useful to say "this theme is neutral, and works both for light
and dark themes". Let me know if you think that's a must-have, otherwise
I think it's probably worth deferring to a follow-up if it's needed at
all.

Differential Revision: https://phabricator.services.mozilla.com/D136354
2022-03-17 14:44:03 +00:00
Ben Hearsum 809783b17a Bug 1751010: Don't change window icon for Private Windows unless privacySegmentation has been enabled. r=mhowell
This was an oversight in the original patch here :(

Differential Revision: https://phabricator.services.mozilla.com/D141269
2022-03-17 13:28:49 +00:00
criss 9302fa739c Backed out 2 changesets (bug 1758702) for causing build bustages. CLOSED TREE
Backed out changeset 3e00d9203851 (bug 1758702)
Backed out changeset 66625baf0875 (bug 1758702)
2022-03-17 15:21:31 +02:00
Emilio Cobos Álvarez 370bce32dc Bug 1758702 - Allow ThreadSafeWeakPtr<IncompleteType> to work. r=glandium
This will be used to avoid problematic includes from WorkerPrivate.h,
and it matches the behavior of RefPtr<> and WeakPtr<>.

Differential Revision: https://phabricator.services.mozilla.com/D140658
2022-03-17 12:15:20 +00:00
Randell Jesup fcaf70841e Bug 1207753 - Add MOZ_UNANNOTATED to all Mutexes/Monitors r=nika,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D140849
2022-03-16 18:47:08 +00:00
Nick Alexander 5764c7d5fd Bug 1753603 - Don't `{Start,Stop}AudioSession` in background tasks. r=mossop
The presenting issue is that each background task's audio session is
user-visible via various Windows UIs that display "volume controls" or
"volume mixers"; this avoids that.

Differential Revision: https://phabricator.services.mozilla.com/D141101
2022-03-16 17:29:37 +00:00
Noemi Erli 2390d257e6 Backed out changeset 12a59e5a50bf (bug 1207753) for causing build bustage CLOSED TREE 2022-03-16 18:32:51 +02:00