else // page change vetoed
{
// tree selection might have already had changed
- tree->SelectItem(DoInternalGetPage(oldSel));
+ if ( oldSel != wxNOT_FOUND )
+ tree->SelectItem(DoInternalGetPage(oldSel));
}
return oldSel;
const wxPoint treePt = tree->ScreenToClient(ClientToScreen(pt));
// is it over the tree?
- if ( wxRect(tree->GetSize()).Inside(treePt) )
+ if ( wxRect(tree->GetSize()).Contains(treePt) )
{
int flagsTree;
wxTreeItemId id = tree->HitTest(treePt, flagsTree);
}
else // not over the tree
{
- if ( flags && GetPageRect().Inside( pt ) )
+ if ( flags && GetPageRect().Contains( pt ) )
*flags |= wxBK_HITTEST_ONPAGE;
}