From: Vadim Zeitlin Date: Sat, 14 Jan 2012 17:57:08 +0000 (+0000) Subject: Update wxNotebook selection when user changes the page in wxOSX. X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/821073e3869477d4d3b365f2bd30a2b264ae486a Update wxNotebook selection when user changes the page in wxOSX. wxNotebook::m_selection was only updated if the selected page was changed programmatically but not if it was done by the user. Do update it in this case as well, it fixes generation of the events which was broken before because of comparison of the new selection with the incorrect current selection value in m_selection. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70340 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/osx/notebook_osx.cpp b/src/osx/notebook_osx.cpp index 68ff2095b5..94d609af4e 100644 --- a/src/osx/notebook_osx.cpp +++ b/src/osx/notebook_osx.cpp @@ -520,6 +520,8 @@ bool wxNotebook::OSXHandleClicked( double WXUNUSED(timestampsec) ) newSel, m_selection ); event.SetEventObject( this ); HandleWindowEvent( event ); + + m_selection = newSel; } else {