Ensure wxTreeCtrl::DoHitTest updates flag when item is successfully hit.

This commit is contained in:
Graham Dawes
2019-02-12 08:47:29 +00:00
parent 78280428e9
commit b9382b99b4

View File

@@ -1286,10 +1286,7 @@ wxTreeItemId wxTreeCtrl::DoTreeHitTest(const wxPoint& point, int& flags) const
return wxTreeItemId();
QTreeWidgetItem *hitItem = m_qtTreeWidget->itemAt(wxQtConvertPoint(point));
if ( hitItem == NULL )
flags |= wxTREE_HITTEST_NOWHERE;
flags = hitItem == NULL ? wxTREE_HITTEST_NOWHERE : wxTREE_HITTEST_ONITEM;
return wxQtConvertTreeItem(hitItem);
}