git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43188
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
{
wxWindow* tab_ctrl = ::wxFindWindowAtPoint(screen_pt);
{
wxWindow* tab_ctrl = ::wxFindWindowAtPoint(screen_pt);
+ // if we aren't over any window, stop here
+ if (!tab_ctrl)
+ return;
+
// make sure we are not over the hint window
// make sure we are not over the hint window
- if (tab_ctrl && !tab_ctrl->IsKindOf(CLASSINFO(wxFrame)))
+ if (!tab_ctrl->IsKindOf(CLASSINFO(wxFrame)))
- wxRect hint_rect = tab_ctrl->GetRect();
+ wxRect hint_rect = tab_ctrl->GetClientRect();
tab_ctrl->ClientToScreen(&hint_rect.x, &hint_rect.y);
m_mgr.ShowHint(hint_rect);
return;
}
tab_ctrl->ClientToScreen(&hint_rect.x, &hint_rect.y);
m_mgr.ShowHint(hint_rect);
return;
}
+ }
+ }
+ else
+ {
+ if (!dest_tabs)
+ {
+ // we are either over a hint window, or not over a tab
+ // window, and there is no where to drag to, so exit
+ return;