// "switch_page"
//-----------------------------------------------------------------------------
+extern "C" {
static void
gtk_mdi_page_change_callback( GtkNotebook *WXUNUSED(widget),
GtkNotebookPage *page,
event2.SetEventObject( child);
child->GetEventHandler()->ProcessEvent( event2 );
}
+}
//-----------------------------------------------------------------------------
// wxMDIParentFrame
/* need to set the menubar of the child */
wxMDIChildFrame *active_child_frame = GetActiveChild();
- wxMenuBar *menu_bar = active_child_frame->m_menuBar;
- if (menu_bar)
+ if (active_child_frame != NULL)
{
- menu_bar->m_width = m_width;
- menu_bar->m_height = wxMENU_HEIGHT;
- gtk_pizza_set_size( GTK_PIZZA(m_mainWidget),
- menu_bar->m_widget,
- 0, 0, m_width, wxMENU_HEIGHT );
- menu_bar->SetInvokingWindow(active_child_frame);
+ wxMenuBar *menu_bar = active_child_frame->m_menuBar;
+ if (menu_bar)
+ {
+ menu_bar->m_width = m_width;
+ menu_bar->m_height = wxMENU_HEIGHT;
+ gtk_pizza_set_size( GTK_PIZZA(m_mainWidget),
+ menu_bar->m_widget,
+ 0, 0, m_width, wxMENU_HEIGHT );
+ menu_bar->SetInvokingWindow(active_child_frame);
+ }
}
-
m_justInserted = false;
return;
}
// "size_allocate"
//-----------------------------------------------------------------------------
+extern "C" {
static void gtk_page_size_callback( GtkWidget *WXUNUSED(widget), GtkAllocation* alloc, wxWindow *win )
{
if (g_isIdle) wxapp_install_idle_handler();
win->SetSize( alloc->x, alloc->y, alloc->width, alloc->height );
}
+}
//-----------------------------------------------------------------------------
// InsertChild callback for wxMDIClientWindow