D15819: [Exe Thumbnailer] Workaround Qt bug in ico detection heuristic

2018-10-01 Thread Kai Uwe Broulik
This revision was automatically updated to reflect the committed changes.
Closed by commit R320:f7be890d3acd: [Exe Thumbnailer] Workaround Qt bug in ico 
detection heuristic (authored by broulik).

REPOSITORY
  R320 KIO Extras

CHANGES SINCE LAST UPDATE
  https://phabricator.kde.org/D15819?vs=42493=42639

REVISION DETAIL
  https://phabricator.kde.org/D15819

AFFECTED FILES
  thumbnail/icoutils_common.cpp

To: broulik, ngraham, anthonyfieroni, cfeck
Cc: cfeck, kde-frameworks-devel, kfm-devel, feverfew, michaelh, spoorun, 
navarromorales, firef, ngraham, andrebarros, bruns, emmanuelp


D15819: [Exe Thumbnailer] Workaround Qt bug in ico detection heuristic

2018-09-28 Thread Christoph Feck
cfeck accepted this revision.
cfeck added inline comments.
This revision is now accepted and ready to land.

INLINE COMMENTS

> icoutils_common.cpp:85
> +// QTBUG-70812: for files with incorrect bits per pixel, 
> QImageReader::canRead() returns
> +// false but it can still correctly determin the imageCount() and read 
> the icon just fine.
> +if (reader.imageCount() == 0) {

determine

REPOSITORY
  R320 KIO Extras

REVISION DETAIL
  https://phabricator.kde.org/D15819

To: broulik, ngraham, anthonyfieroni, cfeck
Cc: cfeck, kde-frameworks-devel, kfm-devel, feverfew, michaelh, spoorun, 
navarromorales, firef, ngraham, andrebarros, bruns, emmanuelp


D15819: [Exe Thumbnailer] Workaround Qt bug in ico detection heuristic

2018-09-28 Thread Kai Uwe Broulik
broulik edited the summary of this revision.

REPOSITORY
  R320 KIO Extras

REVISION DETAIL
  https://phabricator.kde.org/D15819

To: broulik, ngraham, anthonyfieroni
Cc: kde-frameworks-devel, kfm-devel, feverfew, michaelh, spoorun, 
navarromorales, firef, ngraham, andrebarros, bruns, emmanuelp


D15819: [Exe Thumbnailer] Workaround Qt bug in ico detection heuristic

2018-09-28 Thread Kai Uwe Broulik
broulik created this revision.
broulik added reviewers: ngraham, anthonyfieroni.
Herald added projects: Dolphin, Frameworks.
Herald added subscribers: kfm-devel, kde-frameworks-devel.
broulik requested review of this revision.

REVISION SUMMARY
  Ico files mostly contain PNGs these days which retain their image header when 
embedded into an ICO file, so the bits per pixel in the ICO header can be 
missing or incorrect. Qt still manages to extract the underlying PNG just file 
but the `canRead` gives up prematurely.

TEST PLAN
  I now get thumbnails for "sierra chart" exe file

REPOSITORY
  R320 KIO Extras

REVISION DETAIL
  https://phabricator.kde.org/D15819

AFFECTED FILES
  thumbnail/icoutils_common.cpp

To: broulik, ngraham, anthonyfieroni
Cc: kde-frameworks-devel, kfm-devel, feverfew, michaelh, spoorun, 
navarromorales, firef, ngraham, andrebarros, bruns, emmanuelp