]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/assertdlg_gtk.cpp
missing commit
[wxWidgets.git] / src / gtk / assertdlg_gtk.cpp
index 01d9ecdae9b5bcd6c422e509a04c060ebb734494..6f1ef8eb1d3f75c198efa3056f654d7257035a45 100644 (file)
@@ -231,8 +231,9 @@ static void gtk_assert_dialog_continue_callback(GtkWidget*, GtkAssertDialog* dlg
    GtkAssertDialogClass implementation
  ---------------------------------------------------------------------------- */
 
-static void     gtk_assert_dialog_init              (GtkAssertDialog        *self);
-static void     gtk_assert_dialog_class_init        (GtkAssertDialogClass *klass);
+extern "C" {
+static void gtk_assert_dialog_init(GTypeInstance* instance, void*);
+}
 
 GType gtk_assert_dialog_get_type()
 {
@@ -245,12 +246,12 @@ GType gtk_assert_dialog_get_type()
             sizeof (GtkAssertDialogClass),
             NULL,           /* base_init */
             NULL,           /* base_finalize */
-            (GClassInitFunc) gtk_assert_dialog_class_init,
+            NULL,
             NULL,           /* class_finalize */
             NULL,           /* class_data */
             sizeof (GtkAssertDialog),
             16,             /* n_preallocs */
-            (GInstanceInitFunc) gtk_assert_dialog_init,
+            gtk_assert_dialog_init,
             NULL
         };
         assert_dialog_type = g_type_register_static (GTK_TYPE_DIALOG, "GtkAssertDialog", &assert_dialog_info, (GTypeFlags)0);
@@ -259,13 +260,10 @@ GType gtk_assert_dialog_get_type()
     return assert_dialog_type;
 }
 
-static void gtk_assert_dialog_class_init(GtkAssertDialogClass*)
-{
-    /* no special initializations required */
-}
-
-static void gtk_assert_dialog_init(GtkAssertDialog* dlg)
+extern "C" {
+static void gtk_assert_dialog_init(GTypeInstance* instance, void*)
 {
+    GtkAssertDialog* dlg = GTK_ASSERT_DIALOG(instance);
     GtkWidget *continuebtn;
 
     {
@@ -373,6 +371,7 @@ static void gtk_assert_dialog_init(GtkAssertDialog* dlg)
     gtk_widget_pop_composite_child ();
     gtk_widget_show_all (GTK_WIDGET(dlg));
 }
+}
 
 /* ----------------------------------------------------------------------------
    GtkAssertDialog public API
@@ -434,6 +433,8 @@ gchar *gtk_assert_dialog_get_backtrace (GtkAssertDialog *dlg)
     return g_string_free (string, FALSE);
 }
 
+#endif // wxUSE_STACKWALKER
+
 void gtk_assert_dialog_set_message(GtkAssertDialog *dlg, const gchar *msg)
 {
     /* prepend and append the <b> tag
@@ -449,6 +450,8 @@ void gtk_assert_dialog_set_message(GtkAssertDialog *dlg, const gchar *msg)
     g_free (escaped_msg);
 }
 
+#if wxUSE_STACKWALKER
+
 void gtk_assert_dialog_set_backtrace_callback(GtkAssertDialog *assertdlg,
                                               GtkAssertDialogStackFrameCallback callback,
                                               void *userdata)