Bug 256465 - Wrong icon loaded in "mouse down" event
Summary: Wrong icon loaded in "mouse down" event
Status: RESOLVED FIXED
Alias: None
Product: plasma4
Classification: Plasma
Component: widget-folderview (show other bugs)
Version: unspecified
Platform: Unlisted Binaries Linux
: NOR normal
Target Milestone: ---
Assignee: Ignat Semenov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-09 20:19 UTC by markuss
Modified: 2012-05-12 13:39 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In: 4.8.4


Attachments
Screenshot (33.26 KB, image/png)
2010-11-10 12:07 UTC, markuss
Details

Note You need to log in before you can comment on or make changes to this bug.
Description markuss 2010-11-09 20:19:09 UTC
Version:           unspecified (using KDE 4.5.3) 
OS:                Linux

With the recent mimetype icon changes I found a weird behavior in the Folder View plasmoid.

When you select a file and hold down the mouse button, the 256x256 icon version is always loaded in a scaled-down version while the rest of Folder View loads the icons in the correct size (in my case 48x48).

Reproducible: Always

Steps to Reproduce:
Select a file, hold down the mouse button

Actual Results:  
A totally different icon than the usual one.

Expected Results:  
Folder View should use the icon file size selected in its preferences and scale it down by a view pixels to get the same result with correct icons.
Comment 1 markuss 2010-11-10 12:07:30 UTC
Created attachment 53295 [details]
Screenshot
Comment 2 Dario Andres 2010-12-10 21:21:06 UTC
[Comment from a bug triager]
I can reproduce this with KDE SC 4.6beta2 on ArchLinux 686
Comment 3 Thijs 2012-01-17 08:52:06 UTC
..And confirmed on 4.7.4, too
Comment 4 Ignat Semenov 2012-03-03 13:03:32 UTC
Aaawesome! Now this is another confirmation of the dreaded iconloader bug. Thank you for reporting!
Comment 5 Ignat Semenov 2012-05-12 13:39:00 UTC
commit f1ea9f65eaabf3e5e8a6076df580818effcaf7aa
Author: Michael Pyne <mpyne@kde.org>
Date:   Thu May 10 21:59:38 2012 -0400

    Do not force the largest-available icon size to be used.
    
    The current icon-selection code "locks-in" the largest size icon already
    found that is otherwise suitable. This is undesirable since downscaling
    the icon which is the next step up in size should generally be quicker
    and give a more size-appropriate representation on-screen.
    
    Instead of skipping icons that are smaller than an icon already found
    (even if they are a better "fit" for the desired size), we use a simpler
    test to skip icons that require upscaling when we've already found an
    icon that can be downscaled. Otherwise we prefer icons that are closer
    to the desired size.
    
    Issue noted and debugged by Ignat Semenov.
    
    CCMAIL:ragnarokk91@gmail.com