X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/681be2ef80274e6c39b243922a594c59e4983dab..64ea838d8f4d1853b7d850db93ee565e901d099a:/src/os2/notebook.cpp diff --git a/src/os2/notebook.cpp b/src/os2/notebook.cpp index fb45fe10a3..f1c52e8ed4 100644 --- a/src/os2/notebook.cpp +++ b/src/os2/notebook.cpp @@ -60,8 +60,6 @@ BEGIN_EVENT_TABLE(wxNotebook, wxBookCtrlBase) EVT_NAVIGATION_KEY(wxNotebook::OnNavigationKey) END_EVENT_TABLE() -IMPLEMENT_DYNAMIC_CLASS(wxNotebook, wxBookCtrlBase) - // ============================================================================ // implementation // ============================================================================ @@ -75,7 +73,6 @@ IMPLEMENT_DYNAMIC_CLASS(wxNotebook, wxBookCtrlBase) // void wxNotebook::Init() { - m_imageList = NULL; m_nTabSize = 0; } // end of wxNotebook::Init @@ -327,7 +324,7 @@ bool wxNotebook::SetPageImage ( , int nImage ) { - wxBitmap vBitmap = (wxBitmap)m_imageList->GetBitmap(nImage); + wxBitmap vBitmap = (wxBitmap)GetImageList()->GetBitmap(nImage); return (bool)::WinSendMsg( GetHWND() ,BKM_SETTABBITMAP @@ -648,19 +645,7 @@ bool wxNotebook::InsertPage ( size_t nPage, pPage->Show(false); } - // - // Some page should be selected: either this one or the first one if there is - // still no selection - // - int nSelNew = wxNOT_FOUND; - - if (bSelect) - nSelNew = nPage; - else if ( m_selection == wxNOT_FOUND ) - nSelNew = 0; - - if (nSelNew != wxNOT_FOUND) - SetSelection(nSelNew); + DoSetSelectionAfterInsertion(nPage, bSelect); InvalidateBestSize();