X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8907154c1a8a6882c6797d1f16393ddfb23e7f3a..4c20ee63f0c17102213c5c6bb058b7bb9d0ad141:/src/gtk/frame.cpp diff --git a/src/gtk/frame.cpp b/src/gtk/frame.cpp index 70136afb42..d0ade77e6d 100644 --- a/src/gtk/frame.cpp +++ b/src/gtk/frame.cpp @@ -180,11 +180,12 @@ static void wxInsertChildInFrame( wxFrame* parent, wxWindow* child ) wxToolBar *toolBar = (wxToolBar*) child; if (toolBar->GetWindowStyle() & wxTB_DOCKABLE) { - gtk_signal_connect( GTK_OBJECT(toolBar->m_widget), "child_attached", - GTK_SIGNAL_FUNC(gtk_toolbar_attached_callback), (gpointer)parent ); - - gtk_signal_connect( GTK_OBJECT(toolBar->m_widget), "child_detached", - GTK_SIGNAL_FUNC(gtk_toolbar_detached_callback), (gpointer)parent ); + g_signal_connect (toolBar->m_widget, "child_attached", + G_CALLBACK (gtk_toolbar_attached_callback), + parent); + g_signal_connect (toolBar->m_widget, "child_detached", + G_CALLBACK (gtk_toolbar_detached_callback), + parent); } } #endif // wxUSE_TOOLBAR @@ -489,7 +490,12 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y), gtk_pizza_set_size( GTK_PIZZA(m_wxwindow), m_frameStatusBar->m_widget, xx, yy, ww, hh ); - gtk_widget_draw( m_frameStatusBar->m_widget, (GdkRectangle*) NULL ); + if (GTK_WIDGET_DRAWABLE (m_frameStatusBar->m_widget)) + { + gtk_widget_queue_draw (m_frameStatusBar->m_widget); + // FIXME: Do we really want to force an immediate redraw? + gdk_window_process_updates (m_frameStatusBar->m_widget->window, TRUE); + } } #endif // wxUSE_STATUSBAR @@ -558,11 +564,13 @@ void wxFrame::DetachMenuBar() if (m_frameMenuBar->GetWindowStyle() & wxMB_DOCKABLE) { - gtk_signal_disconnect_by_func( GTK_OBJECT(m_frameMenuBar->m_widget), - GTK_SIGNAL_FUNC(gtk_menu_attached_callback), (gpointer)this ); + g_signal_handlers_disconnect_by_func (m_frameMenuBar->m_widget, + (gpointer) gtk_menu_attached_callback, + this); - gtk_signal_disconnect_by_func( GTK_OBJECT(m_frameMenuBar->m_widget), - GTK_SIGNAL_FUNC(gtk_menu_detached_callback), (gpointer)this ); + g_signal_handlers_disconnect_by_func (m_frameMenuBar->m_widget, + (gpointer) gtk_menu_detached_callback, + this); } gtk_widget_ref( m_frameMenuBar->m_widget ); @@ -591,11 +599,12 @@ void wxFrame::AttachMenuBar( wxMenuBar *menuBar ) if (menuBar->GetWindowStyle() & wxMB_DOCKABLE) { - gtk_signal_connect( GTK_OBJECT(menuBar->m_widget), "child_attached", - GTK_SIGNAL_FUNC(gtk_menu_attached_callback), (gpointer)this ); - - gtk_signal_connect( GTK_OBJECT(menuBar->m_widget), "child_detached", - GTK_SIGNAL_FUNC(gtk_menu_detached_callback), (gpointer)this ); + g_signal_connect (menuBar->m_widget, "child_attached", + G_CALLBACK (gtk_menu_attached_callback), + this); + g_signal_connect (menuBar->m_widget, "child_detached", + G_CALLBACK (gtk_menu_detached_callback), + this); } gtk_widget_show( m_frameMenuBar->m_widget );