]> git.saurik.com Git - wxWidgets.git/commitdiff
compilation fix after last change (GTK1 doesn't have g_signal_stop_emission_by_name...
authorVadim Zeitlin <vadim@wxwidgets.org>
Mon, 9 Oct 2006 17:14:31 +0000 (17:14 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Mon, 9 Oct 2006 17:14:31 +0000 (17:14 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@41818 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/gtk1/notebook.cpp

index 7c51c6d91bbeeaa655bb08b9baa8d64a8c5665b7..ddc1c86ddf963116cd652c81aa2577c615113b55 100644 (file)
@@ -118,16 +118,10 @@ static void gtk_notebook_page_change_callback(GtkNotebook *WXUNUSED(widget),
     }
     else
     {
-        wxNotebookEvent eventChanging( wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING,
-                                       notebook->GetId(), page, old );
-        eventChanging.SetEventObject( notebook );
-
-        if ( (notebook->GetEventHandler()->ProcessEvent(eventChanging)) &&
-              !eventChanging.IsAllowed() )
+        if ( !notebook->SendPageChangingEvent(page) )
         {
-            /* program doesn't allow the page change */
-            g_signal_stop_emission_by_name (notebook->m_widget,
-                                            "switch_page");
+            // program doesn't allow the page change
+            gtk_signal_emit_stop_by_name(GTK_OBJECT(notebook->m_widget), "switch_page");
         }
         else // change allowed
         {
@@ -136,10 +130,7 @@ static void gtk_notebook_page_change_callback(GtkNotebook *WXUNUSED(widget),
             // not really changed in GTK+
             notebook->m_selection = page;
 
-            wxNotebookEvent eventChanged( wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED,
-                                          notebook->GetId(), page, old );
-            eventChanged.SetEventObject( notebook );
-            notebook->GetEventHandler()->ProcessEvent( eventChanged );
+            notebook->SendPageChangedEvent(old);
         }
     }