Bug 439589

Summary: albumArtBackground and albumArtImage in tooltips do not appear at the same time
Product: [Plasma] plasmashell Reporter: Fushan Wen <qydwhotmail>
Component: Task Manager and Icons-Only Task ManagerAssignee: Eike Hein <hein>
Status: RESOLVED FIXED    
Severity: minor CC: nate, plasma-bugs
Priority: NOR    
Version: master   
Target Milestone: 1.0   
Platform: unspecified   
OS: Linux   
See Also: https://bugs.kde.org/show_bug.cgi?id=439512
https://bugs.kde.org/show_bug.cgi?id=439687
https://bugs.kde.org/show_bug.cgi?id=439753
Latest Commit: Version Fixed In: 5.23
Attachments: Phenomenon

Description Fushan Wen 2021-07-07 09:23:28 UTC
SUMMARY
When album art image is loaded from a slow net disk, albumArtBackground and albumArtImage often do not appear at the same time because the same image is read twice.

STEPS TO REPRODUCE
1. 
2. 
3. 

OBSERVED RESULT
albumArtBackground and albumArtImage in tooltips do not appear at the same time.

EXPECTED RESULT
albumArtBackground and albumArtImage in tooltips appear at the same time.

SOFTWARE/OS VERSIONS
Operating System: openSUSE Tumbleweed 20210704
KDE Plasma Version: 5.22.2
KDE Frameworks Version: 5.83.0
Qt Version: 5.15.2
Kernel Version: 5.12.13-1-default (64-bit)
Graphics Platform: X11
Processors: 8 × AMD Ryzen 7 4700U with Radeon Graphics
Memory: 15.0 GiB of RAM
Graphics Processor: AMD RENOIR

ADDITIONAL INFORMATION
Comment 1 Bug Janitor Service 2021-07-07 11:48:23 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-desktop/-/merge_requests/525
Comment 2 Fushan Wen 2021-07-11 12:16:11 UTC
Created attachment 139993 [details]
Phenomenon
Comment 3 Nate Graham 2021-08-16 14:56:15 UTC
Git commit 40ce918581328b944c49b7312ec49831d7ad4458 by Nate Graham, on behalf of Fusion Future.
Committed on 16/08/2021 at 14:55.
Pushed by ngraham into branch 'master'.

[Task Manager] Ensure albumArtBackground and albumArtImage display at the same time

Background image and album art image sometimes do not display at the same
time because there are two Image instances referring to the same path, but
cache will not work because they are loaded simultaneously. Use ShaderEffect
instead of another Image instance to provide the background to fix the bug.

Use State and PropertyChanges to avoid unnecessary reevaluation of width
and height of albumArtBackground.

M  +22   -8    applets/taskmanager/package/contents/ui/ToolTipInstance.qml

https://invent.kde.org/plasma/plasma-desktop/commit/40ce918581328b944c49b7312ec49831d7ad4458