X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/0b3b8742c5e6ca7c086264c6518ce6852260bfa2..f549e3dad9b8bed27ba24e2e2f017fd2adfce9be:/src/aui/auibook.cpp diff --git a/src/aui/auibook.cpp b/src/aui/auibook.cpp index 36640c3fcc..f299944023 100644 --- a/src/aui/auibook.cpp +++ b/src/aui/auibook.cpp @@ -2452,6 +2452,7 @@ void wxAuiTabCtrl::OnMotion(wxMouseEvent& evt) button->curState = wxAUI_BUTTON_STATE_HOVER; Refresh(); Update(); + m_hoverButton = button; return; } @@ -4499,7 +4500,9 @@ bool wxAuiNotebook::SetPageImage(size_t n, int imageId) wxWindow* wxAuiNotebook::GetCurrentPage () const { - return GetPage(GetSelection()); + const int sel = GetSelection(); + + return sel == wxNOT_FOUND ? NULL : GetPage(sel); } int wxAuiNotebook::ChangeSelection(size_t n)