[goffice] gtk: use gtk_widget_destroy, not gtk_object_destroy.
- From: Morten Welinder <mortenw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [goffice] gtk: use gtk_widget_destroy, not gtk_object_destroy.
- Date: Mon, 4 Apr 2011 17:00:30 +0000 (UTC)
commit 69ec3e7d0a459520f190dabcb6adbd8358cd97f4
Author: Morten Welinder <terra gnome org>
Date: Mon Apr 4 12:59:25 2011 -0400
gtk: use gtk_widget_destroy, not gtk_object_destroy.
goffice/graph/gog-child-button.c | 4 ++--
goffice/graph/gog-guru.c | 2 +-
goffice/gtk/go-color-palette.c | 2 +-
tests/go-demo.c | 2 +-
tests/mf-demo.c | 6 +++---
tests/pie-demo.c | 4 ++--
6 files changed, 10 insertions(+), 10 deletions(-)
---
diff --git a/goffice/graph/gog-child-button.c b/goffice/graph/gog-child-button.c
index 78288df..8b4b1c5 100644
--- a/goffice/graph/gog-child-button.c
+++ b/goffice/graph/gog-child-button.c
@@ -414,7 +414,7 @@ plot_type_menu_create (GogChildButton *child_button, Addition *addition)
if (closure.non_blank)
return closure.menu;
- gtk_object_destroy (GTK_OBJECT (closure.menu));
+ gtk_widget_destroy (closure.menu);
return NULL;
}
@@ -462,7 +462,7 @@ trend_line_type_menu_create (GogChildButton *child_button, Addition *addition)
if (closure.non_blank)
return closure.menu;
- gtk_object_destroy (GTK_OBJECT (closure.menu));
+ gtk_widget_destroy (closure.menu);
return NULL;
}
diff --git a/goffice/graph/gog-guru.c b/goffice/graph/gog-guru.c
index 75bcfa3..f27d9d1 100644
--- a/goffice/graph/gog-guru.c
+++ b/goffice/graph/gog-guru.c
@@ -1138,7 +1138,7 @@ typesel_set_selection_color (GraphGuruTypeSelector *typesel)
style = go_styled_object_get_style (GO_STYLED_OBJECT (typesel->selector));
style->fill.pattern.back = select_color;
goc_item_invalidate (typesel->selector);
- gtk_object_destroy (GTK_OBJECT (w));
+ gtk_widget_destroy (w);
}
static GtkWidget *
diff --git a/goffice/gtk/go-color-palette.c b/goffice/gtk/go-color-palette.c
index dde1f51..0f1acb8 100644
--- a/goffice/gtk/go-color-palette.c
+++ b/goffice/gtk/go-color-palette.c
@@ -186,7 +186,7 @@ handle_color_sel (GtkColorSelectionDialog *dialog,
*res = GO_COLOR_CHANGE_A (*res, alpha);
}
/* destroy _before_ we emit */
- gtk_object_destroy (GTK_OBJECT (dialog));
+ gtk_widget_destroy (GTK_WIDGET (dialog));
return response_id == GTK_RESPONSE_OK;
}
diff --git a/tests/go-demo.c b/tests/go-demo.c
index c2fbe6f..56a7190 100644
--- a/tests/go-demo.c
+++ b/tests/go-demo.c
@@ -81,7 +81,7 @@ static void generate_all_charts (GtkNotebook *notebook);
static void
on_quit (GtkMenuItem *menuitem, gpointer user_data)
{
- gtk_object_destroy (user_data);
+ gtk_widget_destroy (user_data);
gtk_main_quit ();
}
diff --git a/tests/mf-demo.c b/tests/mf-demo.c
index 1d8c11b..ab68fbf 100644
--- a/tests/mf-demo.c
+++ b/tests/mf-demo.c
@@ -1827,7 +1827,7 @@ init_esc (void)
static void
on_quit (GtkMenuItem *menuitem, gpointer user_data)
{
- gtk_object_destroy (user_data);
+ gtk_widget_destroy (user_data);
gtk_main_quit ();
}
@@ -1894,13 +1894,13 @@ open_file (char const *filename, GtkWidget *nbook)
}
static void
-on_close (GtkObject *object, GtkWidget *nbook)
+on_close (GtkMenuItem *menuitem, GtkWidget *nbook)
{
gtk_widget_destroy (gtk_notebook_get_nth_page (GTK_NOTEBOOK (nbook), gtk_notebook_get_current_page (GTK_NOTEBOOK (nbook))));
}
static void
-on_open (GtkObject *object, GtkWidget *nbook)
+on_open (GtkMenuItem *menuitem, GtkWidget *nbook)
{
GtkWidget *dialog;
diff --git a/tests/pie-demo.c b/tests/pie-demo.c
index 2177a0f..fcbdb74 100644
--- a/tests/pie-demo.c
+++ b/tests/pie-demo.c
@@ -33,9 +33,9 @@
#include <goffice/gtk/go-graph-widget.h>
static void
-on_quit (GtkObject *object)
+on_quit (GtkWidget *w)
{
- gtk_object_destroy (object);
+ gtk_widget_destroy (w);
gtk_main_quit ();
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]