Kaydet (Commit) 593fef7f authored tarafından Colomban Wendling's avatar Colomban Wendling

Don't access GtkWidget:parent directly

üst c7f69973
...@@ -563,7 +563,7 @@ lookup_widget(GtkWidget *widget, const gchar *widget_name) ...@@ -563,7 +563,7 @@ lookup_widget(GtkWidget *widget, const gchar *widget_name)
if (GTK_IS_MENU(widget)) if (GTK_IS_MENU(widget))
parent = gtk_menu_get_attach_widget(GTK_MENU(widget)); parent = gtk_menu_get_attach_widget(GTK_MENU(widget));
else else
parent = widget->parent; parent = gtk_widget_get_parent(widget);
if (parent == NULL) if (parent == NULL)
parent = (GtkWidget*) g_object_get_data(G_OBJECT(widget), "GladeParentKey"); parent = (GtkWidget*) g_object_get_data(G_OBJECT(widget), "GladeParentKey");
if (parent == NULL) if (parent == NULL)
......
...@@ -2439,7 +2439,7 @@ GtkWidget *ui_lookup_widget(GtkWidget *widget, const gchar *widget_name) ...@@ -2439,7 +2439,7 @@ GtkWidget *ui_lookup_widget(GtkWidget *widget, const gchar *widget_name)
if (GTK_IS_MENU(widget)) if (GTK_IS_MENU(widget))
parent = gtk_menu_get_attach_widget(GTK_MENU(widget)); parent = gtk_menu_get_attach_widget(GTK_MENU(widget));
else else
parent = widget->parent; parent = gtk_widget_get_parent(widget);
if (parent == NULL) if (parent == NULL)
parent = (GtkWidget*) g_object_get_data(G_OBJECT(widget), "GladeParentKey"); parent = (GtkWidget*) g_object_get_data(G_OBJECT(widget), "GladeParentKey");
if (parent == NULL) if (parent == NULL)
......
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