fixes 0004059: Tooltips for Gui::QuantitySpinBox not showing [skip ci]
This commit is contained in:
@@ -850,6 +850,16 @@ void QuantitySpinBox::showEvent(QShowEvent * event)
|
||||
|
||||
bool QuantitySpinBox::event(QEvent * event)
|
||||
{
|
||||
// issue #0004059: Tooltips for Gui::QuantitySpinBox not showing
|
||||
// Here we must not try to show the tooltip of the icon label
|
||||
// because it would override a custom tooltip set to this widget.
|
||||
//
|
||||
// We could also check if the text of this tooltip is empty but
|
||||
// it will fail in cases where the widget is embedded into the
|
||||
// property editor and the corresponding item has set a tooltip.
|
||||
// Instead of showing the item's tooltip it will again show the
|
||||
// tooltip of the icon label.
|
||||
#if 0
|
||||
if (event->type() == QEvent::ToolTip) {
|
||||
if (isBound() && getExpression() && lineEdit()->isReadOnly()) {
|
||||
QHelpEvent * helpEvent = static_cast<QHelpEvent*>(event);
|
||||
@@ -859,6 +869,7 @@ bool QuantitySpinBox::event(QEvent * event)
|
||||
return true;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
return QAbstractSpinBox::event(event);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user