From 9cb3bc6ab9a855f29f7c27ee823eee88a568f9dd Mon Sep 17 00:00:00 2001 From: Uwe Rathmann Date: Fri, 23 Sep 2022 12:39:34 +0200 Subject: [PATCH] compare operation fixed --- src/nodes/QskBoxShadowNode.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/nodes/QskBoxShadowNode.cpp b/src/nodes/QskBoxShadowNode.cpp index 44a1af50..17c3a5c5 100644 --- a/src/nodes/QskBoxShadowNode.cpp +++ b/src/nodes/QskBoxShadowNode.cpp @@ -230,12 +230,12 @@ int Material::compare( const QSGMaterial* other ) const { auto material = static_cast< const Material* >( other ); - if ( material->m_color != m_color - || material->m_aspect != m_aspect - || !qFuzzyCompare(material->m_blurExtent, m_blurExtent) - || !qFuzzyCompare(material->m_radius, m_radius) ) + if ( ( material->m_color == m_color ) + && ( material->m_aspect == m_aspect ) + && qFuzzyCompare(material->m_blurExtent, m_blurExtent) + && qFuzzyCompare(material->m_radius, m_radius) ) { - return 1; + return 0; } return QSGMaterial::compare( other );