return false;
m_peer = wxWidgetImpl::CreateTabView(this,parent, id, pos, size, style, GetExtraStyle() );
-
+
MacPostControlCreate( pos, size );
return true ;
return true;
}
-int wxNotebook::HitTest(const wxPoint& pt, long * flags) const
+int wxNotebook::HitTest(const wxPoint& WXUNUSED(pt), long * WXUNUSED(flags)) const
{
int resultV = wxNOT_FOUND;
#if 0
pPage->Layout();
}
+ // If the selected page is hidden at this point, the notebook
+ // has become visible for the first time after creation, and
+ // we postponed showing the page in ChangePage().
+ // So show the selected page now.
+ if ( m_nSelection != -1 )
+ {
+ wxNotebookPage *pPage = m_pages[m_nSelection];
+ if ( !pPage->IsShown() )
+ {
+ pPage->Show( true );
+ pPage->SetFocus();
+ }
+ }
+
// Processing continues to next OnSize
event.Skip();
}
if ( nSel != -1 )
{
wxNotebookPage *pPage = m_pages[nSel];
- pPage->Show( true );
- pPage->SetFocus();
+ if ( IsShownOnScreen() )
+ {
+ pPage->Show( true );
+ pPage->SetFocus();
+ }
+ else
+ {
+ // Postpone Show() until the control is actually shown.
+ // Otherwise this forces the containing toplevel window
+ // to show, even if it's just being created and called
+ // AddPage() without intent to show the window yet.
+ // We Show() the selected page in our OnSize handler,
+ // unless it already is shown.
+ }
}
m_nSelection = nSel;
m_peer->SetValue( m_nSelection + 1 ) ;
}
-bool wxNotebook::HandleClicked( double timestampsec )
+bool wxNotebook::OSXHandleClicked( double WXUNUSED(timestampsec) )
{
bool status = false ;