From b66363d9bde5ad6b425dfabbef62bf6a91ccb765 Mon Sep 17 00:00:00 2001 From: deepin-ci-robot Date: Mon, 16 Dec 2024 07:00:16 +0000 Subject: [PATCH] sync: from linuxdeepin/dtkdeclarative Synchronize source files from linuxdeepin/dtkdeclarative. Source-pull-request: https://github.com/linuxdeepin/dtkdeclarative/pull/434 --- src/private/dquickiconimage.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/private/dquickiconimage.cpp b/src/private/dquickiconimage.cpp index a2f19c11..1cc6335d 100644 --- a/src/private/dquickiconimage.cpp +++ b/src/private/dquickiconimage.cpp @@ -22,7 +22,12 @@ bool DQuickIconImagePrivate::updateDevicePixelRatio(qreal targetDevicePixelRatio return true; } #endif + qreal ratio = devicePixelRatio; devicePixelRatio = targetDevicePixelRatio > 1.0 ? targetDevicePixelRatio : calculateDevicePixelRatio(); + + if (ratio != devicePixelRatio) + maybeUpdateUrl(); + return true; }