Commit 82647966 authored by Morten Welinder's avatar Morten Welinder

gtk: use gtk_widget_destroy, not gtk_object_destroy.

parent 15025a21
......@@ -2329,7 +2329,7 @@ cb_fmt_dialog_dialog_buttons (GtkWidget *btn, FormatState *state)
}
if (btn != state->apply_button)
gtk_object_destroy (GTK_OBJECT (state->dialog));
gtk_widget_destroy (GTK_WIDGET (state->dialog));
}
/* Handler for destroy */
......
......@@ -86,7 +86,7 @@ cb_data_table_response (GtkWidget *dialog, gint response_id, GnmDialogDataTable
state->sheet, &state->input_range,
gnm_expr_entry_get_text (state->col_entry),
gnm_expr_entry_get_text (state->row_entry));
gtk_object_destroy (GTK_OBJECT (dialog));
gtk_widget_destroy (dialog);
}
static gboolean
......
......@@ -52,13 +52,13 @@ cb_response (GtkWidget *dialog,
* This causes crashes with gtk+ 2.10.6, at least.
*/
#if 0
gtk_object_destroy (GTK_OBJECT (dialog));
gtk_widget_destroy (dialog);
#endif
break;
}
default:
gtk_object_destroy (GTK_OBJECT (dialog));
gtk_widget_destroy (dialog);
}
}
......
......@@ -93,7 +93,7 @@ cb_so_list_response (GtkWidget *dialog, gint response_id, GnmDialogSOList *state
(state->as_index_radio)));
}
gtk_object_destroy (GTK_OBJECT (dialog));
gtk_widget_destroy (dialog);
}
static gboolean
......
......@@ -81,7 +81,7 @@ cb_dialog_so_styled_response (GtkWidget *dialog,
pango_attr_list_unref (pref->orig_attributes);
pref->orig_attributes = NULL;
}
gtk_object_destroy (GTK_OBJECT (dialog));
gtk_widget_destroy (dialog);
}
static void
......
......@@ -856,12 +856,12 @@ gnm_pane_dispose (GObject *obj)
GnmPane *pane = GNM_PANE (obj);
if (pane->col.canvas != NULL) {
gtk_object_destroy (GTK_OBJECT (pane->col.canvas));
gtk_widget_destroy (GTK_WIDGET (pane->col.canvas));
pane->col.canvas = NULL;
}
if (pane->row.canvas != NULL) {
gtk_object_destroy (GTK_OBJECT (pane->row.canvas));
gtk_widget_destroy (GTK_WIDGET (pane->row.canvas));
pane->row.canvas = NULL;
}
......
......@@ -346,7 +346,7 @@ icg_finalize (GObject *obj)
G_CALLBACK (cb_icg_window_destroyed), icg);
gtk_window_set_focus (icg->window, NULL);
gtk_window_set_default (icg->window, NULL);
gtk_object_destroy (GTK_OBJECT (icg->window));
gtk_widget_destroy (GTK_WIDGET (icg->window));
}
g_free (icg->progress_msg);
icg->window = NULL;
......
......@@ -1072,7 +1072,7 @@ item_bar_dispose (GObject *obj)
ib_fonts_unref (ib);
if (ib->tip) {
gtk_object_destroy (GTK_OBJECT (ib->tip));
gtk_widget_destroy (ib->tip);
ib->tip = NULL;
}
......
......@@ -653,7 +653,7 @@ cb_table_destroy (SheetControlGUI *scg)
for (i = scg->active_panes; i-- > 0 ; )
if (NULL != scg->pane[i]) {
gtk_object_destroy (GTK_OBJECT (scg->pane[i]));
gtk_widget_destroy (GTK_WIDGET (scg->pane[i]));
scg->pane[i] = NULL;
}
......@@ -1137,7 +1137,7 @@ scg_set_panes (SheetControl *sc)
int i;
for (i = 1 ; i <= 3 ; i++)
if (scg->pane[i]) {
gtk_object_destroy (GTK_OBJECT (scg->pane[i]));
gtk_widget_destroy (GTK_WIDGET (scg->pane[i]));
scg->pane[i] = NULL;
}
......@@ -1681,7 +1681,7 @@ scg_finalize (GObject *object)
}
if (scg->table) {
gtk_object_destroy (GTK_OBJECT (scg->table));
gtk_widget_destroy (GTK_WIDGET (scg->table));
g_object_unref (scg->table);
scg->table = NULL;
}
......@@ -3013,7 +3013,7 @@ scg_comment_unselect (SheetControlGUI *scg, GnmComment *cc)
scg_comment_timer_clear (scg);
if (scg->comment.item != NULL) {
gtk_object_destroy (GTK_OBJECT (scg->comment.item));
gtk_widget_destroy (scg->comment.item);
scg->comment.item = NULL;
}
}
......
......@@ -709,7 +709,7 @@ cb_sheet_label_drag_end (GtkWidget *widget, GdkDragContext *context,
/* Destroy the arrow. */
arrow = g_object_get_data (G_OBJECT (widget), "arrow");
gtk_object_destroy (GTK_OBJECT (arrow));
gtk_widget_destroy (arrow);
g_object_unref (arrow);
g_object_set_data (G_OBJECT (widget), "arrow", NULL);
}
......@@ -5321,7 +5321,7 @@ wbc_gtk_finalize (GObject *obj)
gtk_window_set_focus (wbcg_toplevel (wbcg), NULL);
if (wbcg->toplevel != NULL) {
gtk_object_destroy (GTK_OBJECT (wbcg->toplevel));
gtk_widget_destroy (wbcg->toplevel);
wbcg->toplevel = NULL;
}
......
......@@ -464,7 +464,7 @@ gee_set_property (GObject *object,
G_CALLBACK (cb_icon_clicked), gee);
}
} else if (gee->icon != NULL)
gtk_object_destroy (GTK_OBJECT (gee->icon));
gtk_widget_destroy (gee->icon);
break;
case PROP_TEXT: {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment