tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

commit bceee66d097b580bf91fa58c1c4571b08fb041f8
parent ea5cdb606718658bbea1d5c4fca0dcc9e3e06430
Author: Sotaro Ikeda <sotaro.ikeda.g@gmail.com>
Date:   Wed, 10 Dec 2025 03:47:46 +0000

Bug 2005100 - Perfer overlay than underlay r=gfx-reviewers,lsalzman

Power usage of overlay could be more efficient than underlay.

When overlay could not be used, underlay is selected.

Differential Revision: https://phabricator.services.mozilla.com/D275717

Diffstat:
Mgfx/wr/webrender/src/picture.rs | 9++-------
1 file changed, 2 insertions(+), 7 deletions(-)

diff --git a/gfx/wr/webrender/src/picture.rs b/gfx/wr/webrender/src/picture.rs @@ -3428,13 +3428,8 @@ impl TileCacheInstance { // is necessary for correct color display. let force = prim_data.kind.color_depth.bit_depth() > 8; - let clip_on_top = prim_clip_chain.needs_mask; - let prefer_underlay = clip_on_top || !cfg!(target_os = "macos"); - let promotion_attempts = if prefer_underlay { - [CompositorSurfaceKind::Underlay, CompositorSurfaceKind::Overlay] - } else { - [CompositorSurfaceKind::Overlay, CompositorSurfaceKind::Underlay] - }; + let promotion_attempts = + [CompositorSurfaceKind::Overlay, CompositorSurfaceKind::Underlay]; for kind in promotion_attempts { // Since this might be an attempt after an earlier error, clear the flag