micheleg / dash-to-dock

A dock for the Gnome Shell. This extension moves the dash out of the overview transforming it in a dock for an easier launching of applications and a faster switching between windows and desktops.
https://micheleg.github.io/dash-to-dock/
GNU General Public License v2.0
3.82k stars 463 forks source link

Fix for blurry background when opening a new application #2147

Closed sniirful closed 4 months ago

sniirful commented 4 months ago

When a new application is opened, the background usually results in being blurry, unless the mouse cursor hovers over the dash, just like in the following screenshots: image image

Such a problem was already well documented in the issue #1722.

This pull request fixes this issue by overriding the show() method from DashItemContainer in DockDashItemContainer and simulating a hover over the item once the animation is finished.

3v1n0 commented 4 months ago

What happens if the application is launched from another launcher or using the keyboard, is the forced-hover causing any side-effect?

sniirful commented 4 months ago

What happens if the application is launched from another launcher or using the keyboard, is the forced-hover causing any side-effect?

I've tested it using a Fedora 39 virtual machine and launching the app both by pressing the Super key and typing the app name, and by pressing Ctrl-Alt-T after setting it as a keyboard shortcut in the settings: Screencast from 2024-02-16 15-57-15.webm Screencast from 2024-02-16 15-57-38.webm

I apologize for the videos appearing with weird coloring (maybe that's a virtio bug?) but you can still clearly see that the animation has the background blurry and it unblurs only when the animation finishes. It's a bit annoying but it's not as annoying as having it always blurry.

I'm still wondering if we can ever understand the root reason though :)

I'm not sure whether this issue can be attributed to how GNOME renders objects, it almost looks like it always keeps the same background resolution as the first frame it rendered. Since it renders the object by directly animating it, it looks like when it renders the first frame of the animation it doesn't bother to upscale it later. This might seem just an assumption but it can be verified by two tests:

stuarthayhurst commented 4 months ago

The root cause seems to have been identified here: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/6567#note_2020532

The blurry issues seem to apply to the shutdown / reboot popup briefly, app icon backgrounds and desktop thumbnails.