From 19001d9cfe83d4f435bd953264a75e1e938540db Mon Sep 17 00:00:00 2001 From: Syres916 <46537884+Syres916@users.noreply.github.com> Date: Thu, 24 Jul 2025 10:59:29 +0100 Subject: [PATCH] [Gui] Property Editor allow double-click of separators --- src/Gui/propertyeditor/PropertyItemDelegate.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/Gui/propertyeditor/PropertyItemDelegate.cpp b/src/Gui/propertyeditor/PropertyItemDelegate.cpp index a85ccf4559..c9f355340d 100644 --- a/src/Gui/propertyeditor/PropertyItemDelegate.cpp +++ b/src/Gui/propertyeditor/PropertyItemDelegate.cpp @@ -163,7 +163,10 @@ void PropertyItemDelegate::paint(QPainter *painter, const QStyleOptionViewItem & bool PropertyItemDelegate::editorEvent (QEvent * event, QAbstractItemModel* model, const QStyleOptionViewItem& option, const QModelIndex& index) { - if (!event || event->type() == QEvent::MouseButtonDblClick) { + auto property = static_cast(index.internalPointer()); + + if ((property && !property->isSeparator()) + && (!event || event->type() == QEvent::MouseButtonDblClick)) { // ignore double click, as it could cause editor lock with checkboxes // due to the editor being close immediately after toggling the checkbox // which is currently done on first click