git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@2493
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
// Name: msw/notebook.cpp
// Purpose: implementation of wxNotebook
// Author: Vadim Zeitlin
// Name: msw/notebook.cpp
// Purpose: implementation of wxNotebook
// Author: Vadim Zeitlin
// Created: 11.06.98
// RCS-ID: $Id$
// Copyright: (c) 1998 Vadim Zeitlin <zeitlin@dptmaths.ens-cachan.fr>
// Created: 11.06.98
// RCS-ID: $Id$
// Copyright: (c) 1998 Vadim Zeitlin <zeitlin@dptmaths.ens-cachan.fr>
(WPARAM)::GetStockObject(DEFAULT_GUI_FONT),TRUE);
(WPARAM)::GetStockObject(DEFAULT_GUI_FONT),TRUE);
SubclassWin(m_hWnd);
return TRUE;
SubclassWin(m_hWnd);
return TRUE;
}
void wxNotebook::SetImageList(wxImageList* imageList)
}
void wxNotebook::SetImageList(wxImageList* imageList)
m_pImageList = imageList;
TabCtrl_SetImageList(m_hwnd, (HIMAGELIST)imageList->GetHIMAGELIST());
}
m_pImageList = imageList;
TabCtrl_SetImageList(m_hwnd, (HIMAGELIST)imageList->GetHIMAGELIST());
}
// remove all pages
bool wxNotebook::DeleteAllPages()
{
// remove all pages
bool wxNotebook::DeleteAllPages()
{
- TabCtrl_DeleteAllItems(m_hwnd);
-
int nPageCount = GetPageCount();
int nPage;
for ( nPage = 0; nPage < nPageCount; nPage++ )
int nPageCount = GetPageCount();
int nPage;
for ( nPage = 0; nPage < nPageCount; nPage++ )
+ TabCtrl_DeleteAllItems(m_hwnd);
+
// save the pointer to the page
m_aPages.Insert(pPage, nPage);
// save the pointer to the page
m_aPages.Insert(pPage, nPage);
- // some page must be selected: either this one or the first one if there is
+ // some page must be selected: either this one or the first one if there is
// still no selection
if ( bSelect )
m_nSelection = nPage;
// still no selection
if ( bSelect )
m_nSelection = nPage;