mirror of
https://invent.kde.org/system/dolphin
synced 2024-08-22 01:40:02 +00:00
Fix rare ToolTipManager crash on exit
If tooltips are enabled and you hover over item while immediately closing Dolphin sometimes it would crash because native parent might have been destroyed before DolphinView
This commit is contained in:
parent
957e6309b8
commit
fc2d181291
|
@ -1225,7 +1225,10 @@ void DolphinView::slotItemHovered(int index)
|
|||
itemRect.moveTo(pos);
|
||||
|
||||
#ifdef HAVE_BALOO
|
||||
m_toolTipManager->showToolTip(item, itemRect, nativeParentWidget()->windowHandle());
|
||||
auto nativeParent = nativeParentWidget();
|
||||
if (nativeParent) {
|
||||
m_toolTipManager->showToolTip(item, itemRect, nativeParent->windowHandle());
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue