From 3cfa0c0de71eee4b550206742a8831f245b3e03a Mon Sep 17 00:00:00 2001 From: Tobias Hunger Date: Wed, 26 Oct 2016 12:48:17 +0200 Subject: [PATCH] Qt: Do not send dataChanged if nothing changed When setting the warning/error icon on a Qt version in the Qt options page: Do not send dataChanged if the icon has not actually changed. This fixes the selection getting broken when two Qt versions happen to have the same displayName. Task-number: QTCREATORBUG-16644 Change-Id: I7722fbc021388be237e59a59bd136c61f611ad52 Reviewed-by: Tobias Hunger --- src/plugins/qtsupport/qtoptionspage.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/plugins/qtsupport/qtoptionspage.cpp b/src/plugins/qtsupport/qtoptionspage.cpp index 9667a5aa89e..30290d76987 100644 --- a/src/plugins/qtsupport/qtoptionspage.cpp +++ b/src/plugins/qtsupport/qtoptionspage.cpp @@ -116,6 +116,8 @@ public: void setIcon(const QIcon &icon) { + if (m_icon.cacheKey() == icon.cacheKey()) + return; m_icon = icon; update(); }