+ GetBool(wxT("selected")));
+ if ( HasParam(wxT("bitmap")) )
+ {
+ wxBitmap bmp = GetBitmap(wxT("bitmap"), wxART_OTHER);
+ wxImageList *imgList = m_notebook->GetImageList();
+ if ( imgList == NULL )
+ {
+ imgList = new wxImageList( bmp.GetWidth(), bmp.GetHeight() );
+ m_notebook->AssignImageList( imgList );
+ }
+ int imgIndex = imgList->Add(bmp);
+ m_notebook->SetPageImage(m_notebook->GetPageCount()-1, imgIndex );
+ }
+ else if ( HasParam(wxT("image")) )
+ {
+ if ( m_notebook->GetImageList() )
+ {
+ m_notebook->SetPageImage(m_notebook->GetPageCount()-1,
+ GetLong(wxT("image")) );
+ }
+ else // image without image list?
+ {
+ ReportError(n, "image can only be used in conjunction "
+ "with imagelist");
+ }
+ }
+ }