diff --git a/src/commoncomponents/ResponsiveImage.qml b/src/commoncomponents/ResponsiveImage.qml index 3626056200056c3d2a880efc09b1a2f081d59048..a727c627d49c1128931a63cdded4b76dfc1c667c 100644 --- a/src/commoncomponents/ResponsiveImage.qml +++ b/src/commoncomponents/ResponsiveImage.qml @@ -61,19 +61,15 @@ Image { } function setSourceSize() { - if (ScreenInfo.getDevicePixelRatio() === 1.0) - return - if (isSvg) { - sourceSize = undefined + sourceSize = undefined + if (isSvg) sourceSize = Qt.size(width, height) - } else - sourceSize = undefined } Connections { target: ScreenInfo - function onDevicePixelRatioChanged(){ + function onDevicePixelRatioChanged() { setSourceSize() } } diff --git a/src/mainapplication.h b/src/mainapplication.h index e71303adc9fb9a19031a712d046de7e237fc3e79..881155d5c05fc05863e00b4a883cecbf03e8ec45 100644 --- a/src/mainapplication.h +++ b/src/mainapplication.h @@ -50,10 +50,6 @@ public: Q_EMIT devicePixelRatioChanged(); } } - Q_INVOKABLE double getDevicePixelRatio() - { - return devicePixelRatio_; - } Q_SIGNALS: void devicePixelRatioChanged();