X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/409f747ed9f08095e81aea317e1ed19410a1664d..424da8bdb9f05243d8888d78a56ab0cc3f615a6c:/src/msw/notebook.cpp diff --git a/src/msw/notebook.cpp b/src/msw/notebook.cpp index 05a1136e4a..4b3c6e0aee 100644 --- a/src/msw/notebook.cpp +++ b/src/msw/notebook.cpp @@ -454,11 +454,13 @@ int wxNotebook::SetSelection(size_t nPage) if ( SendPageChangingEvent(nPage) ) { // program allows the page change - SendPageChangedEvent(m_selection, nPage); + const int selectionOld = m_selection; UpdateSelection(nPage); TabCtrl_SetCurSel(GetHwnd(), nPage); + + SendPageChangedEvent(selectionOld, nPage); } }