Skip to content

qt: fix scaling when either width or height is 0 broken due to using uninitialized size in `SVGColorImageReader`

Fatih Uzunoğlu requested to merge fuzun/vlc:qt/uninitializedscaledsize into master

I do not set scaledSize to requested size by default, just to partially override it when either width or height is 0. However, this means that we need to initialize the uninitialized part manually by setting it to non-zero requested size counterpart as I proposed here.

I did not realize this because the case in NetworkCustomCover still worked with this bug (sourceSize: Qt.size(0, height) // preserve aspect ratio), because the image there has anchors so the display size did not change.

Request review @chub.

Edited by Fatih Uzunoğlu

Merge request reports

Loading