diff --git a/src/engraving/dom/score.cpp b/src/engraving/dom/score.cpp index c3e9d745caa82..dba5f90a49177 100644 --- a/src/engraving/dom/score.cpp +++ b/src/engraving/dom/score.cpp @@ -1734,7 +1734,8 @@ void Score::doUndoRemoveElement(EngravingItem* element) { if (element->generated()) { removeElement(element); - element->deleteLater(); + //! HACK: don't delete as it may still be used in Inspector + // element->deleteLater(); } else { undo(new RemoveElement(element)); } diff --git a/src/inspector/models/notation/notes/beams/beamsettingsmodel.cpp b/src/inspector/models/notation/notes/beams/beamsettingsmodel.cpp index 1d274787799c2..0e038d5a4c5be 100644 --- a/src/inspector/models/notation/notes/beams/beamsettingsmodel.cpp +++ b/src/inspector/models/notation/notes/beams/beamsettingsmodel.cpp @@ -96,11 +96,9 @@ void BeamSettingsModel::loadProperties() loadProperties(propertyIdSet); } -void BeamSettingsModel::onNotationChanged(const PropertyIdSet&, const StyleIdSet&) +void BeamSettingsModel::onNotationChanged(const PropertyIdSet& changedPropertyIdSet, const StyleIdSet&) { - // The list of elements may have become invalid; beams might have been deleted and replaced during layout. - // Request the actual list to prevent crashes. TODO: Not ideal for performance though. - updateProperties(); + loadProperties(changedPropertyIdSet); } void BeamSettingsModel::loadProperties(const mu::engraving::PropertyIdSet& propertyIdSet)