Commit c856737c authored by Tristan Van Berkom's avatar Tristan Van Berkom
Browse files

* Made GladeWidget internalize *everything* into a private data structure,

	33 files changed, 1318 insertions(+), 1230 deletions(-)
parent ccfac250
......@@ -13,6 +13,9 @@
* gladeui/glade-widget.[ch]: Added the "in_project" flag to GladeWidget, fixed glade_widget_rebuild
to save the previous project pointer.
* Made GladeWidget internalize *everything* into a private data structure,
33 files changed, 1318 insertions(+), 1230 deletions(-)
2010-12-31 Tristan Van Berkom <tristanvb@openismus.com>
* gladeui/glade-project.c: Further fixing project dispose cycle, still leaking a little
......
......@@ -1167,8 +1167,7 @@ glade_app_command_paste (GladePlaceholder * placeholder)
if (placeholder)
{
if (glade_placeholder_get_project (placeholder) == NULL ||
glade_project_is_loading (glade_placeholder_get_project
(placeholder)))
glade_project_is_loading (glade_placeholder_get_project (placeholder)))
return;
}
......@@ -1186,14 +1185,14 @@ glade_app_command_paste (GladePlaceholder * placeholder)
/* Ignore parent argument if we are pasting a toplevel
*/
if (g_list_length (clipboard->selection) == 1 &&
widget && GWA_IS_TOPLEVEL (widget->adaptor))
widget && GWA_IS_TOPLEVEL (glade_widget_get_adaptor (widget)))
parent = NULL;
if (parent && GLADE_IS_FIXED (parent))
fixed = GLADE_FIXED (parent);
/* Check if parent is actually a container of any sort */
if (parent && !glade_widget_adaptor_is_container (parent->adaptor))
if (parent && !glade_widget_adaptor_is_container (glade_widget_get_adaptor (parent)))
{
glade_util_ui_message (glade_app_get_window (),
GLADE_UI_INFO, NULL,
......@@ -1217,7 +1216,7 @@ glade_app_command_paste (GladePlaceholder * placeholder)
/* Abort operation when adding a non scrollable widget to any kind of GtkScrolledWindow. */
if (parent && widget &&
glade_util_check_and_warn_scrollable (parent, widget->adaptor,
glade_util_check_and_warn_scrollable (parent, glade_widget_get_adaptor (widget),
glade_app_get_window ()))
return;
......@@ -1235,7 +1234,7 @@ glade_app_command_paste (GladePlaceholder * placeholder)
{
widget = list->data;
if (!GWA_IS_TOPLEVEL (widget->adaptor) && parent)
if (!GWA_IS_TOPLEVEL (glade_widget_get_adaptor (widget)) && parent)
{
/* Count placeholder relations
*/
......@@ -1249,9 +1248,9 @@ glade_app_command_paste (GladePlaceholder * placeholder)
/* A GladeFixed that doesnt use placeholders can only paste one
* at a time
*/
if (GTK_IS_WIDGET (widget->object) &&
gtk_widget_is_toplevel (GTK_WIDGET (widget->object)) == FALSE &&
parent && fixed && !GWA_USE_PLACEHOLDERS (parent->adaptor) &&
if (GTK_IS_WIDGET (glade_widget_get_object (widget)) &&
parent && fixed &&
!GWA_USE_PLACEHOLDERS (glade_widget_get_adaptor (parent)) &&
g_list_length (clipboard->selection) != 1)
{
glade_util_ui_message (glade_app_get_window (),
......@@ -1263,7 +1262,7 @@ glade_app_command_paste (GladePlaceholder * placeholder)
/* Check that enough placeholders are available */
if (parent &&
GWA_USE_PLACEHOLDERS (parent->adaptor) &&
GWA_USE_PLACEHOLDERS (glade_widget_get_adaptor (parent)) &&
glade_util_count_placeholders (parent) < placeholder_relations)
{
glade_util_ui_message (glade_app_get_window (),
......
......@@ -239,7 +239,6 @@ static void
glade_base_editor_fill_store_real (GladeBaseEditor * e,
GladeWidget * gwidget, GtkTreeIter * parent)
{
GObject *object = glade_widget_get_object (gwidget);
GList *children, *l;
GladeWidget *gparent = NULL;
GtkTreeIter iter;
......@@ -249,50 +248,45 @@ glade_base_editor_fill_store_real (GladeBaseEditor * e,
GLADE_BASE_EDITOR_GWIDGET, &gparent, -1);
children = glade_widget_adaptor_get_children (gwidget->adaptor, object);
children = glade_widget_get_children (gwidget);
for (l = children; l; l = l->next)
{
GObject *child = (GObject *) l->data;
GladeWidget *gchild;
if (child && (gchild = glade_widget_get_from_gobject (child)))
{
gchar *type_name = NULL, *name;
/* Have to check parents here for compatibility (could be the parenting menuitem of this menu
* supports a menuitem...) */
if (glade_base_editor_get_type_info (e, NULL,
G_OBJECT_TYPE (child),
GLADE_BASE_EDITOR_CLASS_NAME,
&type_name, -1))
{
gtk_tree_store_append (GTK_TREE_STORE (e->priv->model), &iter,
parent);
name = glade_base_editor_get_display_name (e, gchild);
gtk_tree_store_set (GTK_TREE_STORE (e->priv->model), &iter,
GLADE_BASE_EDITOR_GWIDGET, gchild,
GLADE_BASE_EDITOR_OBJECT, child,
GLADE_BASE_EDITOR_TYPE_NAME, type_name,
GLADE_BASE_EDITOR_NAME, name,
GLADE_BASE_EDITOR_CHILD_TYPES,
get_children_model_for_child_type (e,
G_OBJECT_TYPE
(child)),
-1);
glade_base_editor_fill_store_real (e, gchild, &iter);
g_free (name);
g_free (type_name);
}
else
glade_base_editor_fill_store_real (e, gchild, parent);
}
GObject *child = (GObject *) l->data;
gchar *type_name = NULL, *name;
gchild = glade_widget_get_from_gobject (child);
/* Have to check parents here for compatibility (could be the parenting menuitem of this menu
* supports a menuitem...) */
if (glade_base_editor_get_type_info (e, NULL,
G_OBJECT_TYPE (child),
GLADE_BASE_EDITOR_CLASS_NAME,
&type_name, -1))
{
gtk_tree_store_append (GTK_TREE_STORE (e->priv->model), &iter, parent);
name = glade_base_editor_get_display_name (e, gchild);
gtk_tree_store_set (GTK_TREE_STORE (e->priv->model), &iter,
GLADE_BASE_EDITOR_GWIDGET, gchild,
GLADE_BASE_EDITOR_OBJECT, child,
GLADE_BASE_EDITOR_TYPE_NAME, type_name,
GLADE_BASE_EDITOR_NAME, name,
GLADE_BASE_EDITOR_CHILD_TYPES,
get_children_model_for_child_type (e,
G_OBJECT_TYPE
(child)),
-1);
glade_base_editor_fill_store_real (e, gchild, &iter);
g_free (name);
g_free (type_name);
}
else
glade_base_editor_fill_store_real (e, gchild, parent);
}
g_list_free (children);
......@@ -356,13 +350,11 @@ glade_base_editor_name_activate (GtkEntry * entry, GladeWidget * gchild)
if (text && text[0] && strcmp (glade_widget_get_name (gchild), text))
{
g_signal_handlers_block_by_func (gchild->project,
glade_base_editor_project_widget_name_changed,
editor);
g_signal_handlers_block_by_func (glade_widget_get_project (gchild),
glade_base_editor_project_widget_name_changed, editor);
glade_command_set_name (gchild, text);
g_signal_handlers_unblock_by_func (gchild->project,
glade_base_editor_project_widget_name_changed,
editor);
g_signal_handlers_unblock_by_func (glade_widget_get_project (gchild),
glade_base_editor_project_widget_name_changed, editor);
}
}
......@@ -538,10 +530,10 @@ glade_base_editor_child_change_type (GladeBaseEditor * editor,
if (type == G_OBJECT_TYPE (child))
return;
if (!gchild || !gchild->parent)
if (!gchild || !glade_widget_get_parent (gchild))
return;
gparent = gchild->parent;
gparent = glade_widget_get_parent (gchild);
/* Start of glade-command */
......@@ -725,8 +717,8 @@ glade_base_editor_add_child (GladeBaseEditor * editor,
GLADE_BASE_EDITOR_NAME, name,
GLADE_BASE_EDITOR_CHILD_TYPES,
get_children_model_for_type (editor,
G_OBJECT_TYPE (gparent->
object)), -1);
G_OBJECT_TYPE (glade_widget_get_object (gparent))),
-1);
glade_base_editor_reorder_children (editor, &new_iter);
......@@ -766,12 +758,10 @@ glade_base_editor_popup (GladeBaseEditor * editor, GladeWidget * widget)
if ((model =
get_children_model_for_child_type (editor,
G_OBJECT_TYPE (widget->object))) ==
NULL)
G_OBJECT_TYPE (glade_widget_get_object (widget)))) == NULL)
model =
get_children_model_for_type (editor,
G_OBJECT_TYPE (editor->priv->gcontainer->
object));
get_children_model_for_type (editor,
G_OBJECT_TYPE (glade_widget_get_object (editor->priv->gcontainer)));
g_assert (model);
......@@ -808,7 +798,7 @@ glade_base_editor_popup (GladeBaseEditor * editor, GladeWidget * widget)
if ((model =
get_children_model_for_type (editor, G_OBJECT_TYPE (widget->object))) &&
get_children_model_for_type (editor, G_OBJECT_TYPE (glade_widget_get_object (widget)))) &&
gtk_tree_model_get_iter_first (model, &iter))
do
{
......@@ -936,7 +926,7 @@ static gboolean
glade_base_editor_is_child (GladeBaseEditor * e,
GladeWidget * gchild, gboolean valid_type)
{
GladeWidget *gcontainer = gchild->parent;
GladeWidget *gcontainer = glade_widget_get_parent (gchild);
if (!gcontainer)
return FALSE;
......@@ -945,7 +935,7 @@ glade_base_editor_is_child (GladeBaseEditor * e,
{
GObject *child = glade_widget_get_object (gchild);
if (gchild->internal ||
if (glade_widget_get_internal (gchild) ||
glade_base_editor_get_type_info (e, NULL,
G_OBJECT_TYPE (child), -1) == FALSE)
return FALSE;
......@@ -1103,7 +1093,8 @@ glade_base_editor_project_remove_widget (GladeProject * project,
}
}
if (widget->internal && glade_base_editor_is_child (e, widget, FALSE))
if (glade_widget_get_internal (widget) &&
glade_base_editor_is_child (e, widget, FALSE))
glade_base_editor_update_properties (e);
}
......@@ -1120,7 +1111,8 @@ glade_base_editor_project_add_widget (GladeProject * project,
g_idle_add (glade_base_editor_update_treeview_idle, e);
}
if (widget->internal && glade_base_editor_is_child (e, widget, FALSE))
if (glade_widget_get_internal (widget) &&
glade_base_editor_is_child (e, widget, FALSE))
glade_base_editor_update_properties (e);
}
......@@ -1298,7 +1290,7 @@ glade_base_editor_get_property (GObject * object,
switch (prop_id)
{
case PROP_CONTAINER:
g_value_set_object (value, editor->priv->gcontainer->object);
g_value_set_object (value, glade_widget_get_object (editor->priv->gcontainer));
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
......@@ -1344,7 +1336,7 @@ glade_base_editor_change_type (GladeBaseEditor * editor,
{
GladeWidget *w = glade_widget_get_from_gobject (l->data);
if (w && !w->internal)
if (w && !glade_widget_get_internal (w))
gchildren = g_list_prepend (gchildren, w);
l = g_list_next (l);
......@@ -1370,7 +1362,7 @@ glade_base_editor_change_type (GladeBaseEditor * editor,
* No need to use GladeCommand here on the newly created widget,
* they just become the initial state for this object.
*/
l = gchild->packing_properties;
l = glade_widget_get_packing_properties (gchild);
while (l)
{
GladeProperty *orig_prop = (GladeProperty *) l->data;
......@@ -1895,8 +1887,8 @@ glade_base_editor_new (GObject * container, GladeEditable * main_editable, ...)
/* Invent one if not provided */
if (!main_editable)
main_editable =
glade_widget_adaptor_create_editable (gcontainer->adaptor,
GLADE_PAGE_GENERAL);
glade_widget_adaptor_create_editable (glade_widget_get_adaptor (gcontainer),
GLADE_PAGE_GENERAL);
glade_editable_load (main_editable, gcontainer);
gtk_widget_show (GTK_WIDGET (main_editable));
......@@ -2004,7 +1996,7 @@ glade_base_editor_add_default_properties (GladeBaseEditor * editor,
g_return_if_fail (GLADE_IS_BASE_EDITOR (editor));
g_return_if_fail (GLADE_IS_WIDGET (gchild));
g_return_if_fail (GLADE_IS_WIDGET (gchild->parent));
g_return_if_fail (GLADE_IS_WIDGET (glade_widget_get_parent (gchild)));
child = glade_widget_get_object (gchild);
......@@ -2107,7 +2099,7 @@ glade_base_editor_add_editable (GladeBaseEditor * editor,
g_return_if_fail (GLADE_IS_BASE_EDITOR (editor));
g_return_if_fail (GLADE_IS_WIDGET (gchild));
editable = glade_widget_adaptor_create_editable (gchild->adaptor, page);
editable = glade_widget_adaptor_create_editable (glade_widget_get_adaptor (gchild), page);
glade_editable_set_show_name (editable, FALSE);
glade_editable_load (editable, gchild);
gtk_widget_show (GTK_WIDGET (editable));
......
This diff is collapsed.
......@@ -1532,7 +1532,8 @@ glade_eprop_text_changed_common (GladeEditorProperty * eprop,
{
val = glade_property_class_make_gvalue_from_string
(eprop->property->klass, text,
eprop->property->widget->project, eprop->property->widget);
glade_widget_get_project (eprop->property->widget),
eprop->property->widget);
}
else
{
......@@ -1896,7 +1897,7 @@ static void
glade_eprop_text_show_resource_dialog (GtkWidget * entry,
GladeEditorProperty * eprop)
{
GladeProject *project = eprop->property->widget->project;
GladeProject *project = glade_widget_get_project (eprop->property->widget);
gchar *text = NULL;
if (glade_editor_property_show_resource_dialog (project, entry, &text))
......@@ -2380,21 +2381,22 @@ glade_eprop_object_populate_view_real (GtkTreeStore * model,
for (list = widgets; list; list = list->next)
{
GladeWidget *widget;
GladeWidgetAdaptor *adaptor;
if ((widget = glade_widget_get_from_gobject (list->data)) != NULL)
{
adaptor = glade_widget_get_adaptor (widget);
has_decendant = !parentless && glade_widget_has_decendant
(widget, object_type);
good_type = (widget->adaptor->type == object_type ||
g_type_is_a (widget->adaptor->type, object_type) ||
glade_util_class_implements_interface (widget->adaptor->
type,
good_type = (adaptor->type == object_type ||
g_type_is_a (adaptor->type, object_type) ||
glade_util_class_implements_interface (adaptor->type,
object_type));
if (parentless)
good_type = good_type && !GWA_IS_TOPLEVEL (widget->adaptor);
good_type = good_type && !GWA_IS_TOPLEVEL (adaptor);
if (good_type || has_decendant)
{
......@@ -2403,8 +2405,8 @@ glade_eprop_object_populate_view_real (GtkTreeStore * model,
(model, &iter,
OBJ_COLUMN_WIDGET, widget,
OBJ_COLUMN_WIDGET_NAME,
glade_eprop_object_name (widget->name, model, parent_iter),
OBJ_COLUMN_WIDGET_CLASS, widget->adaptor->title,
glade_eprop_object_name (glade_widget_get_name (widget), model, parent_iter),
OBJ_COLUMN_WIDGET_CLASS, adaptor->title,
/* Selectable if its a compatible type and
* its not itself.
*/
......@@ -2416,7 +2418,7 @@ glade_eprop_object_populate_view_real (GtkTreeStore * model,
if (has_decendant &&
(children = glade_widget_adaptor_get_children
(widget->adaptor, widget->object)) != NULL)
(adaptor, glade_widget_get_object (widget))) != NULL)
{
GtkTreeIter *copy = NULL;
......@@ -2451,7 +2453,7 @@ glade_eprop_object_populate_view (GladeProject * project,
GladeWidget *gwidget = glade_widget_get_from_gobject (object);
g_assert (gwidget);
if (gwidget->parent == NULL)
if (glade_widget_get_parent (gwidget) == NULL)
toplevels = g_list_append (toplevels, object);
}
......@@ -2863,11 +2865,13 @@ glade_eprop_object_show_dialog (GtkWidget * dialog_button,
{
GValue *value;
glade_project_selection_set (project, eprop->property->widget->object,
glade_project_selection_set (project,
glade_widget_get_object (eprop->property->widget),
TRUE);
value = glade_property_class_make_gvalue_from_string
(eprop->klass, selected->name, project, eprop->property->widget);
(eprop->klass, glade_widget_get_name (selected),
project, eprop->property->widget);
/* Unparent the widget so we can reuse it for this property */
if (eprop->klass->parentless_widget)
......@@ -2891,10 +2895,9 @@ glade_eprop_object_show_dialog (GtkWidget * dialog_button,
glade_widget_get_parentless_widget_ref (new_widget)))
{
glade_command_push_group (_("Setting %s of %s to %s"),
eprop->property->klass->
name,
eprop->property->widget->
name, new_widget->name);
eprop->property->klass->name,
glade_widget_get_name (eprop->property->widget),
glade_widget_get_name (new_widget));
glade_command_set_property (old_ref, NULL);
glade_editor_property_commit (eprop, value);
glade_command_pop_group ();
......@@ -2920,17 +2923,16 @@ glade_eprop_object_show_dialog (GtkWidget * dialog_button,
glade_command_push_group (_("Creating %s for %s of %s"),
create_adaptor->name,
eprop->property->klass->name,
eprop->property->widget->name);
glade_widget_get_name (eprop->property->widget));
/* Dont bother if the user canceled the widget */
if ((new_widget =
glade_command_create (create_adaptor, NULL, NULL, project)) != NULL)
{
glade_project_selection_set (project, eprop->property->widget->object,
TRUE);
glade_project_selection_set (project, glade_widget_get_object (eprop->property->widget), TRUE);
value = glade_property_class_make_gvalue_from_string
(eprop->klass, new_widget->name, project, NULL);
(eprop->klass, glade_widget_get_name (new_widget), project, NULL);
glade_editor_property_commit (eprop, value);
......@@ -3064,7 +3066,8 @@ glade_eprop_objects_selected_widget (GtkTreeModel * model,
if (selected)
{
*ret = g_list_append (*ret, widget->object);
*ret = g_list_append (*ret, glade_widget_get_object (widget));
g_object_unref (widget);
}
return FALSE;
......
......@@ -137,7 +137,8 @@ widget_name_edited (GtkWidget * editable, GladeEditorTable * table)
widget = table->loaded_widget;
new_name = gtk_editable_get_chars (GTK_EDITABLE (editable), 0, -1);
if (glade_project_available_widget_name (widget->project, widget, new_name))
if (glade_project_available_widget_name (glade_widget_get_project (widget),
widget, new_name))
glade_command_set_name (widget, new_name);
g_free (new_name);
}
......@@ -153,7 +154,7 @@ widget_name_changed (GladeWidget * widget,
{
BLOCK_NAME_ENTRY_CB (table);
gtk_entry_set_text (GTK_ENTRY (table->name_entry),
table->loaded_widget->name);
glade_widget_get_name (table->loaded_widget));
UNBLOCK_NAME_ENTRY_CB (table);
}
......@@ -204,7 +205,8 @@ glade_editor_table_load (GladeEditable * editable, GladeWidget * widget)
(GWeakNotify) widget_finalized, table);
if (table->name_entry)
gtk_entry_set_text (GTK_ENTRY (table->name_entry), widget->name);
gtk_entry_set_text (GTK_ENTRY (table->name_entry),
glade_widget_get_name (widget));
}
else if (table->name_entry)
......
......@@ -254,9 +254,9 @@ glade_editor_on_docs_click (GtkButton * button, GladeEditor * editor)
if (editor->loaded_widget)
{
g_object_get (editor->loaded_widget->adaptor, "book", &book, NULL);
g_object_get (editor->loaded_adaptor, "book", &book, NULL);
glade_editor_search_doc_search (editor, book,
editor->loaded_widget->adaptor->name,
editor->loaded_adaptor->name,
NULL);
g_free (book);
}
......@@ -308,12 +308,12 @@ static void
glade_editor_update_class_warning_cb (GladeWidget * widget,
GParamSpec * pspec, GladeEditor * editor)
{
if (widget->support_warning)
if (glade_widget_support_warning (widget))
gtk_widget_show (editor->warning);
else
gtk_widget_hide (editor->warning);
gtk_widget_set_tooltip_text (editor->warning, widget->support_warning);
gtk_widget_set_tooltip_text (editor->warning, glade_widget_support_warning (widget));
}
......@@ -326,14 +326,15 @@ glade_editor_update_class_field (GladeEditor * editor)
gchar *text;
gtk_image_set_from_icon_name (GTK_IMAGE (editor->class_icon),
widget->adaptor->icon_name,
editor->loaded_adaptor->icon_name,
GTK_ICON_SIZE_BUTTON);
gtk_widget_show (editor->class_icon);
/* translators: referring to the properties of a widget named '%s [%s]' */
text = g_strdup_printf (_("%s Properties - %s [%s]"),
widget->adaptor->title,
widget->adaptor->name, widget->name);
editor->loaded_adaptor->title,
editor->loaded_adaptor->name,
glade_widget_get_name (widget));
gtk_label_set_text (GTK_LABEL (editor->class_label), text);
g_free (text);
......@@ -644,21 +645,24 @@ static void
glade_editor_load_editable (GladeEditor * editor,
GladeWidget * widget, GladeEditorPageType type)
{
GtkWidget *editable;
GtkWidget *editable;
GladeWidget *parent = glade_widget_get_parent (widget);
/* Use the parenting adaptor for packing pages... so deffer creating the widgets
* until load time.
*/
if (type == GLADE_PAGE_PACKING && widget->parent)
if (type == GLADE_PAGE_PACKING && parent)
{
GladeWidgetAdaptor *adaptor = widget->parent->adaptor;
GladeWidgetAdaptor *adaptor = glade_widget_get_adaptor (parent);
editable =
glade_editor_load_editable_in_page (editor, adaptor,
GLADE_PAGE_PACKING);
}
else
editable = glade_editor_get_editable_by_adaptor
(editor, widget->adaptor, type);
editable =
glade_editor_get_editable_by_adaptor (editor,
glade_widget_get_adaptor (widget),
type);
g_assert (editable);
......@@ -711,7 +715,7 @@ glade_editor_load_widget_real (GladeEditor * editor, GladeWidget * widget)
}
/* Load the GladeWidgetClass */
adaptor = widget ? widget->adaptor : NULL;
adaptor = widget ? glade_widget_get_adaptor (widget) : NULL;
if (editor->loaded_adaptor != adaptor || adaptor == NULL)
glade_editor_load_widget_class (editor, adaptor);
......@@ -823,19 +827,23 @@ query_dialog_style_set_cb (GtkWidget * dialog,
gboolean
glade_editor_query_dialog (GladeEditor * editor, GladeWidget * widget)
{
GladeWidgetAdaptor *adaptor;
GtkWidget *dialog, *editable, *content_area;
gchar *title;
gint answer;
gboolean retval = TRUE;
title = g_strdup_printf (_("Create a %s"), widget->adaptor->name);
g_return_val_if_fail (GLADE_IS_EDITOR (editor), FALSE);
g_return_val_if_fail (GLADE_IS_WIDGET (widget), FALSE);
adaptor = glade_widget_get_adaptor (widget);
title = g_strdup_printf (_("Create a %s"), adaptor->name);
dialog = gtk_dialog_new_with_buttons (title, NULL,
GTK_DIALOG_MODAL |
GTK_DIALOG_DESTROY_WITH_PARENT,
GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL,
GTK_STOCK_OK, GTK_RESPONSE_OK, NULL);
g_free (title);
gtk_dialog_set_alternative_button_order (GTK_DIALOG (dialog),
......@@ -843,9 +851,7 @@ glade_editor_query_dialog (GladeEditor * editor, GladeWidget * widget)
GTK_RESPONSE_CANCEL, -1);
gtk_dialog_set_default_response (GTK_DIALOG (dialog), GTK_RESPONSE_OK);
editable = glade_editor_get_editable_by_adaptor (editor,
widget->adaptor,
GLADE_PAGE_QUERY);
editable = glade_editor_get_editable_by_adaptor (editor, adaptor, GLADE_PAGE_QUERY);
content_area = gtk_dialog_get_content_area (GTK_DIALOG (dialog));
gtk_box_pack_start (GTK_BOX (content_area), editable, FALSE, FALSE, 6);
......@@ -1004,7 +1010,7 @@ glade_editor_populate_reset_view (GladeEditor * editor, GtkTreeView * tree_view)
COLUMN_DEFAULT, FALSE, COLUMN_NDEFAULT, FALSE, -1);
/* General & Common */
for (list = editor->loaded_widget->properties; list; list = list->next)
for (list = glade_widget_get_properties (editor->loaded_widget