From 05f064aa2bb54ea30d2f37d7d3ca8ebb9ffd678f Mon Sep 17 00:00:00 2001 From: Emma Broman Date: Wed, 21 May 2025 10:27:47 +0200 Subject: [PATCH] Fix so property visibility change is respected also for currently hidden properties We only subscribe to changes for visible properties, so here we need to notify the property owner about the change --- src/properties/property.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/properties/property.cpp b/src/properties/property.cpp index 9ca43b2168..fb80b23377 100644 --- a/src/properties/property.cpp +++ b/src/properties/property.cpp @@ -24,6 +24,8 @@ #include +#include +#include #include #include #include @@ -101,6 +103,15 @@ std::string Property::groupIdentifier() const { void Property::setVisibility(Visibility visibility) { _metaData.visibility = visibility; notifyMetaDataChangeListeners(); + + // We only subscribe to meta data changes for visible properties, so if the + // visibility changes during runtime, we need to notify the property owner + // about the change for it to affect properties that are currently hidden + if (_owner) { + global::eventEngine->publishEvent( + _owner->uri() + ); + } } Property::Visibility Property::visibility() const {