app/widgets/gimpdocked.[ch] renamed GimpDockedIface to
2003-10-11 Sven Neumann <sven@gimp.org> * app/widgets/gimpdocked.[ch] * app/widgets/widgets-types.h: renamed GimpDockedIface to GimpDockedInterface. * app/display/gimpnavigationview.c * app/widgets/gimpcoloreditor.c * app/widgets/gimpcontainereditor.c * app/widgets/gimpcontainerview.c * app/widgets/gimpeditor.c * app/widgets/gimpimageeditor.c * app/widgets/gimpitemtreeview.c * app/widgets/gimptooloptionseditor.c: changed accordingly. * app/config/config-types.h * app/config/gimpconfig.[ch] * app/config/gimpconfig-deserialize.[ch] * app/config/gimpconfig-serialize.[ch] * app/config/gimpconfig-utils.[ch]: added a GimpConfig typedef and changed the GimpConfig API to take GimpConfig instead of GObject pointers. * app/config/gimpconfig-dump.c * app/config/gimprc.c * app/config/test-config.c * app/core/gimp-documents.c * app/core/gimp-parasites.c * app/core/gimp-templates.c * app/core/gimp.[ch] * app/core/gimpcontainer.c * app/core/gimpcontext.c * app/core/gimpdocumentlist.c * app/core/gimpgrid.c * app/core/gimpimage-duplicate.c * app/core/gimpimage-new.c * app/core/gimpimage.c * app/core/gimpparasitelist.c * app/core/gimptemplate.c * app/core/gimptooloptions.c * app/core/gimpviewable.c * app/gui/grid-dialog.c * app/gui/preferences-dialog.c * app/gui/stroke-dialog.c * app/gui/templates-commands.c * app/gui/tool-options-commands.c * app/paint/gimppaintcore.c * app/pdb/gimprc_cmds.c * app/text/gimptext-parasite.c * app/text/gimptext.c * app/text/gimptextlayer.c * app/tools/gimp-tools.c * app/tools/gimptexttool.c * app/widgets/gimpdevices.c * app/widgets/gimptemplateeditor.c * app/widgets/gimptemplateview.c * tools/pdbgen/pdb/gimprc.pdb: changed accordingly.
This commit is contained in:
committed by
Sven Neumann
parent
99746e1d6c
commit
a88e11afb3
@ -101,10 +101,10 @@ static void gimp_container_get_property (GObject *object,
|
||||
static gsize gimp_container_get_memsize (GimpObject *object,
|
||||
gsize *gui_size);
|
||||
|
||||
static gboolean gimp_container_serialize (GObject *object,
|
||||
static gboolean gimp_container_serialize (GimpConfig *config,
|
||||
GimpConfigWriter *writer,
|
||||
gpointer data);
|
||||
static gboolean gimp_container_deserialize (GObject *object,
|
||||
static gboolean gimp_container_deserialize (GimpConfig *config,
|
||||
GScanner *scanner,
|
||||
gint nest_level,
|
||||
gpointer data);
|
||||
@ -148,8 +148,7 @@ gimp_container_get_type (void)
|
||||
"GimpContainer",
|
||||
&container_info, 0);
|
||||
|
||||
g_type_add_interface_static (container_type,
|
||||
GIMP_TYPE_CONFIG_INTERFACE,
|
||||
g_type_add_interface_static (container_type, GIMP_TYPE_CONFIG,
|
||||
&config_iface_info);
|
||||
}
|
||||
|
||||
@ -375,7 +374,7 @@ gimp_container_serialize_foreach (GObject *object,
|
||||
GimpConfigInterface *config_iface;
|
||||
const gchar *name;
|
||||
|
||||
config_iface = GIMP_GET_CONFIG_INTERFACE (object);
|
||||
config_iface = GIMP_CONFIG_GET_INTERFACE (object);
|
||||
|
||||
if (! config_iface)
|
||||
serialize_data->success = FALSE;
|
||||
@ -393,21 +392,21 @@ gimp_container_serialize_foreach (GObject *object,
|
||||
else
|
||||
gimp_config_writer_print (serialize_data->writer, "NULL", 4);
|
||||
|
||||
serialize_data->success = config_iface->serialize (object,
|
||||
serialize_data->success = config_iface->serialize (GIMP_CONFIG (object),
|
||||
serialize_data->writer,
|
||||
serialize_data->data);
|
||||
gimp_config_writer_close (serialize_data->writer);
|
||||
}
|
||||
|
||||
static gboolean
|
||||
gimp_container_serialize (GObject *object,
|
||||
gimp_container_serialize (GimpConfig *config,
|
||||
GimpConfigWriter *writer,
|
||||
gpointer data)
|
||||
{
|
||||
GimpContainer *container;
|
||||
SerializeData serialize_data;
|
||||
|
||||
container = GIMP_CONTAINER (object);
|
||||
container = GIMP_CONTAINER (config);
|
||||
|
||||
serialize_data.writer = writer;
|
||||
serialize_data.data = data;
|
||||
@ -421,15 +420,15 @@ gimp_container_serialize (GObject *object,
|
||||
}
|
||||
|
||||
static gboolean
|
||||
gimp_container_deserialize (GObject *object,
|
||||
GScanner *scanner,
|
||||
gint nest_level,
|
||||
gpointer data)
|
||||
gimp_container_deserialize (GimpConfig *config,
|
||||
GScanner *scanner,
|
||||
gint nest_level,
|
||||
gpointer data)
|
||||
{
|
||||
GimpContainer *container;
|
||||
GTokenType token;
|
||||
|
||||
container = GIMP_CONTAINER (object);
|
||||
container = GIMP_CONTAINER (config);
|
||||
|
||||
token = G_TOKEN_LEFT_PAREN;
|
||||
|
||||
@ -468,7 +467,7 @@ gimp_container_deserialize (GObject *object,
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if (! g_type_is_a (type, GIMP_TYPE_CONFIG_INTERFACE))
|
||||
if (! g_type_is_a (type, GIMP_TYPE_CONFIG))
|
||||
{
|
||||
g_scanner_error (scanner,
|
||||
"'%s' does not implement GimpConfigInterface",
|
||||
@ -509,20 +508,14 @@ gimp_container_deserialize (GObject *object,
|
||||
|
||||
g_free (name);
|
||||
|
||||
{
|
||||
GimpConfigInterface *config_iface;
|
||||
|
||||
config_iface = GIMP_GET_CONFIG_INTERFACE (child);
|
||||
|
||||
if (! config_iface->deserialize (G_OBJECT (child),
|
||||
scanner,
|
||||
nest_level + 1,
|
||||
FALSE))
|
||||
{
|
||||
/* warning should be already set by child */
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
if (! GIMP_CONFIG_GET_INTERFACE (config)->deserialize (GIMP_CONFIG (child),
|
||||
scanner,
|
||||
nest_level + 1,
|
||||
FALSE))
|
||||
{
|
||||
/* warning should be already set by child */
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
token = G_TOKEN_RIGHT_PAREN;
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user