Commit de7a9405 authored by Michael Natterer's avatar Michael Natterer 😴 Committed by Michael Natterer
Browse files

app/config/gimpconfig-deserialize.c app/config/gimpscanner.c

2004-05-12  Michael Natterer  <mitch@gimp.org>

	* app/config/gimpconfig-deserialize.c
	* app/config/gimpscanner.c
	* app/core/gimp-edit.c
	* app/core/gimpchannel-combine.c
	* app/core/gimpcontainer.c
	* app/core/gimpdrawable-bucket-fill.c
	* app/core/gimpdrawable-combine.c
	* app/core/gimpdrawable.c
	* app/core/gimpgradient.c
	* app/core/gimpimage-flip.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage-projection.c
	* app/core/gimpimage.c
	* app/display/gimpdisplay-handlers.c
	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpprogress.c
	* app/gui/info-dialog.c
	* app/gui/module-browser.c
	* app/gui/offset-dialog.c
	* app/plug-in/plug-in.c
	* app/tools/gimpdrawtool.c
	* app/tools/tool_manager.c
	* app/widgets/gimpactiongroup.c
	* app/widgets/gimpdialogfactory.c
	* app/widgets/gimpgradienteditor.c
	* app/widgets/gimpitemfactory.c
	* app/widgets/gimppropwidgets.c
	* app/widgets/gimpwidgets-utils.c
	* app/xcf/xcf-save.c
	* libgimp/gimpexport.c
	* libgimpwidgets/gimphelpui.c
	* libgimpwidgets/gimppixmap.c
	* libgimpwidgets/gimpunitmenu.c: replaced G_GNUC_FUNCTION,
	G_GNUC_PRETTY_FUNCTION, G_STRLOC and hardcoded function names in
	g_warning()s by G_STRFUNC.
parent e6342de9
2004-05-12 Michael Natterer <mitch@gimp.org>
* app/config/gimpconfig-deserialize.c
* app/config/gimpscanner.c
* app/core/gimp-edit.c
* app/core/gimpchannel-combine.c
* app/core/gimpcontainer.c
* app/core/gimpdrawable-bucket-fill.c
* app/core/gimpdrawable-combine.c
* app/core/gimpdrawable.c
* app/core/gimpgradient.c
* app/core/gimpimage-flip.c
* app/core/gimpimage-merge.c
* app/core/gimpimage-projection.c
* app/core/gimpimage.c
* app/display/gimpdisplay-handlers.c
* app/display/gimpdisplayshell-callbacks.c
* app/display/gimpprogress.c
* app/gui/info-dialog.c
* app/gui/module-browser.c
* app/gui/offset-dialog.c
* app/plug-in/plug-in.c
* app/tools/gimpdrawtool.c
* app/tools/tool_manager.c
* app/widgets/gimpactiongroup.c
* app/widgets/gimpdialogfactory.c
* app/widgets/gimpgradienteditor.c
* app/widgets/gimpitemfactory.c
* app/widgets/gimppropwidgets.c
* app/widgets/gimpwidgets-utils.c
* app/xcf/xcf-save.c
* libgimp/gimpexport.c
* libgimpwidgets/gimphelpui.c
* libgimpwidgets/gimppixmap.c
* libgimpwidgets/gimpunitmenu.c: replaced G_GNUC_FUNCTION,
G_GNUC_PRETTY_FUNCTION, G_STRLOC and hardcoded function names in
g_warning()s by G_STRFUNC.
2004-05-12 Michael Natterer <mitch@gimp.org>
* app/actions/gradients-actions.c
......
......@@ -314,7 +314,8 @@ gimp_config_deserialize_property (GimpConfig *config,
#ifdef CONFIG_DEBUG
else
{
g_warning ("couldn't deserialize property %s::%s of type %s",
g_warning ("%s: couldn't deserialize property %s::%s of type %s",
G_STRFUNC,
g_type_name (G_TYPE_FROM_INSTANCE (config)),
prop_spec->name,
g_type_name (prop_spec->value_type));
......@@ -731,7 +732,7 @@ gimp_config_deserialize_any (GValue *value,
if (!g_value_type_transformable (G_TYPE_STRING, prop_spec->value_type))
{
g_warning ("%s: %s can not be transformed from a string",
G_STRLOC, g_type_name (prop_spec->value_type));
G_STRFUNC, g_type_name (prop_spec->value_type));
return G_TOKEN_NONE;
}
......
......@@ -167,7 +167,7 @@ gimp_scanner_destroy (GScanner *scanner)
{
if (close (data->fd))
g_warning ("%s: could not close file descriptor: %s",
G_GNUC_PRETTY_FUNCTION, g_strerror (errno));
G_STRFUNC, g_strerror (errno));
}
g_free (data->name);
......
......@@ -300,7 +300,7 @@ gimp_edit_fill (GimpImage *gimage,
return TRUE; /* nothing to do, but the fill succeded */
default:
g_warning ("%s: unknown fill type", G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: unknown fill type", G_STRFUNC);
fill_type = GIMP_BACKGROUND_FILL;
undo_desc = _("Fill with BG Color");
break;
......
......@@ -489,7 +489,7 @@ gimp_channel_combine_mask (GimpChannel *mask,
break;
default:
g_warning ("%s: unknown operation type\n", G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: unknown operation type", G_STRFUNC);
break;
}
......
......@@ -564,8 +564,8 @@ gimp_container_add (GimpContainer *container,
if (gimp_container_have (container, object))
{
g_warning ("%s(): container %p already contains object %p",
G_GNUC_FUNCTION, container, object);
g_warning ("%s: container %p already contains object %p",
G_STRFUNC, container, object);
return FALSE;
}
......@@ -618,8 +618,8 @@ gimp_container_remove (GimpContainer *container,
if (! gimp_container_have (container, object))
{
g_warning ("%s(): container %p does not contain object %p",
G_GNUC_FUNCTION, container, object);
g_warning ("%s: container %p does not contain object %p",
G_STRFUNC, container, object);
return FALSE;
}
......@@ -675,8 +675,8 @@ gimp_container_insert (GimpContainer *container,
if (gimp_container_have (container, object))
{
g_warning ("%s(): container %p already contains object %p",
G_GNUC_FUNCTION, container, object);
g_warning ("%s: container %p already contains object %p",
G_STRFUNC, container, object);
return FALSE;
}
......@@ -704,8 +704,8 @@ gimp_container_reorder (GimpContainer *container,
if (! gimp_container_have (container, object))
{
g_warning ("%s(): container %p does not contain object %p",
G_GNUC_FUNCTION, container, object);
g_warning ("%s: container %p does not contain object %p",
G_STRFUNC, container, object);
return FALSE;
}
......@@ -900,7 +900,7 @@ gimp_container_add_handler (GimpContainer *container,
handler->callback_data = callback_data;
handler->quark = g_quark_from_string (key);
D (g_print ("%s: key = %s, id = %d\n", G_GNUC_FUNCTION, key, handler->quark));
D (g_print ("%s: key = %s, id = %d\n", G_STRFUNC, key, handler->quark));
g_free (key);
......@@ -951,11 +951,11 @@ gimp_container_remove_handler (GimpContainer *container,
if (! list)
{
g_warning ("%s: tried to remove handler which unknown id %d",
G_STRLOC, id);
G_STRFUNC, id);
return;
}
D (g_print ("%s: id = %d\n", G_GNUC_FUNCTION, handler->quark));
D (g_print ("%s: id = %d\n", G_STRFUNC, handler->quark));
gimp_container_foreach (container,
(GFunc) gimp_container_remove_handler_foreach_func,
......
......@@ -89,7 +89,7 @@ gimp_drawable_bucket_fill (GimpDrawable *drawable,
}
else
{
g_warning ("%s: invalid fill_mode passed", G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: invalid fill_mode passed", G_STRFUNC);
return;
}
......@@ -158,7 +158,7 @@ gimp_drawable_bucket_fill_full (GimpDrawable *drawable,
}
else
{
g_warning ("%s: invalid fill_mode passed", G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: invalid fill_mode passed", G_STRFUNC);
return;
}
......
......@@ -71,7 +71,7 @@ gimp_drawable_real_apply_region (GimpDrawable *drawable,
src2PR->bytes);
if (operation == -1)
{
g_warning ("%s: illegal parameters.", G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: illegal parameters.", G_STRFUNC);
return;
}
......@@ -193,7 +193,7 @@ gimp_drawable_real_replace_region (GimpDrawable *drawable,
src2PR->bytes);
if (operation == -1)
{
g_warning ("%s: illegal parameters.", G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: illegal parameters.", G_STRFUNC);
return;
}
......
......@@ -982,7 +982,7 @@ gimp_drawable_push_undo (GimpDrawable *drawable,
gimp_item_height (item),
&x, &y, &width, &height))
{
g_warning ("gimp_drawable_push_undo: tried to push empty region");
g_warning ("%s: tried to push empty region", G_STRFUNC);
return;
}
......@@ -1138,7 +1138,7 @@ gimp_drawable_fill_by_type (GimpDrawable *drawable,
return;
default:
g_warning ("%s: unknown fill type %d", G_GNUC_PRETTY_FUNCTION, fill_type);
g_warning ("%s: unknown fill type %d", G_STRFUNC, fill_type);
return;
}
......
......@@ -709,7 +709,7 @@ gimp_gradient_get_color_at (GimpGradient *gradient,
default:
g_warning ("%s: Unknown gradient type %d.",
G_GNUC_PRETTY_FUNCTION, seg->type);
G_STRFUNC, seg->type);
break;
}
......@@ -768,8 +768,8 @@ gimp_gradient_get_color_at (GimpGradient *gradient,
break;
default:
g_warning ("%s(): Unknown coloring mode %d",
G_GNUC_PRETTY_FUNCTION, (gint) seg->color);
g_warning ("%s: Unknown coloring mode %d",
G_STRFUNC, (gint) seg->color);
break;
}
......@@ -821,8 +821,8 @@ gimp_gradient_get_segment_at (GimpGradient *gradient,
}
/* Oops: we should have found a segment, but we didn't */
g_warning ("%s(): no matching segment for position %0.15f",
G_GNUC_PRETTY_FUNCTION, pos);
g_warning ("%s: no matching segment for position %0.15f",
G_STRFUNC, pos);
return NULL;
}
......
......@@ -62,7 +62,7 @@ gimp_image_flip (GimpImage *gimage,
break;
default:
g_warning ("gimp_image_flip(): unknown flip_type");
g_warning ("%s: unknown flip_type", G_STRFUNC);
return;
}
......
......@@ -325,8 +325,7 @@ gimp_image_merge_layers (GimpImage *gimage,
GIMP_OPACITY_OPAQUE, GIMP_NORMAL_MODE);
if (!merge_layer)
{
g_warning ("%s: could not allocate merge layer.",
G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: could not allocate merge layer.", G_STRFUNC);
return NULL;
}
......@@ -365,8 +364,7 @@ gimp_image_merge_layers (GimpImage *gimage,
if (!merge_layer)
{
g_warning ("%s: could not allocate merge layer",
G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: could not allocate merge layer", G_STRFUNC);
return NULL;
}
......@@ -417,8 +415,7 @@ gimp_image_merge_layers (GimpImage *gimage,
if (operation == -1)
{
g_warning ("%s: attempting to merge incompatible layers.",
G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: attempting to merge incompatible layers.", G_STRFUNC);
return NULL;
}
......
......@@ -726,7 +726,7 @@ project_indexed (GimpImage *gimage,
gimage->visible,
INITIAL_INDEXED);
else
g_warning ("%s: unable to project indexed image.", G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: unable to project indexed image.", G_STRFUNC);
}
static void
......
......@@ -2097,8 +2097,7 @@ gimp_image_get_new_tattoo (GimpImage *gimage)
gimage->tattoo_state++;
if (gimage->tattoo_state <= 0)
g_warning ("%s: Tattoo state corrupted (integer overflow).",
G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: Tattoo state corrupted (integer overflow).", G_STRFUNC);
return gimage->tattoo_state;
}
......@@ -2526,15 +2525,13 @@ gimp_image_add_layer (GimpImage *gimage,
if (GIMP_ITEM (layer)->gimage != NULL &&
GIMP_ITEM (layer)->gimage != gimage)
{
g_warning ("%s: attempting to add layer to wrong image.",
G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: attempting to add layer to wrong image.", G_STRFUNC);
return FALSE;
}
if (gimp_container_have (gimage->layers, GIMP_OBJECT (layer)))
{
g_warning ("%s: trying to add layer to image twice.",
G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: trying to add layer to image twice.", G_STRFUNC);
return FALSE;
}
......@@ -2543,8 +2540,7 @@ gimp_image_add_layer (GimpImage *gimage,
if (floating_sel && gimp_layer_is_floating_sel (layer))
{
g_warning ("%s: trying to add floating layer to image which alyready "
"has a floating selection.",
G_GNUC_PRETTY_FUNCTION);
"has a floating selection.", G_STRFUNC);
return FALSE;
}
......@@ -2855,15 +2851,13 @@ gimp_image_add_channel (GimpImage *gimage,
if (GIMP_ITEM (channel)->gimage != NULL &&
GIMP_ITEM (channel)->gimage != gimage)
{
g_warning ("%s: attempting to add channel to wrong image.",
G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: attempting to add channel to wrong image.", G_STRFUNC);
return FALSE;
}
if (gimp_container_have (gimage->channels, GIMP_OBJECT (channel)))
{
g_warning ("%s: trying to add channel to image twice.",
G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: trying to add channel to image twice.", G_STRFUNC);
return FALSE;
}
......@@ -3095,15 +3089,13 @@ gimp_image_add_vectors (GimpImage *gimage,
if (GIMP_ITEM (vectors)->gimage != NULL &&
GIMP_ITEM (vectors)->gimage != gimage)
{
g_warning ("%s: attempting to add vectors to wrong image.",
G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: attempting to add vectors to wrong image.", G_STRFUNC);
return FALSE;
}
if (gimp_container_have (gimage->vectors, GIMP_OBJECT (vectors)))
{
g_warning ("%s: trying to add vectors to image twice.",
G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: trying to add vectors to image twice.", G_STRFUNC);
return FALSE;
}
......
......@@ -726,7 +726,7 @@ project_indexed (GimpImage *gimage,
gimage->visible,
INITIAL_INDEXED);
else
g_warning ("%s: unable to project indexed image.", G_GNUC_PRETTY_FUNCTION);
g_warning ("%s: unable to project indexed image.", G_STRFUNC);
}
static void
......
......@@ -475,7 +475,7 @@ info_dialog_update_field (InfoField *field)
break;
default:
g_warning ("%s: Unknown info_dialog field type.", G_STRLOC);
g_warning ("%s: Unknown info_dialog field type.", G_STRFUNC);
break;
}
......
......@@ -296,7 +296,7 @@ browser_autoload_toggled (GtkCellRendererToggle *celltoggle,
path = gtk_tree_path_new_from_string (path_string);
if (! gtk_tree_model_get_iter (GTK_TREE_MODEL (browser->list), &iter, path))
{
g_warning ("%s: bad tree path?", G_STRLOC);
g_warning ("%s: bad tree path?", G_STRFUNC);
return;
}
gtk_tree_path_free (path);
......@@ -393,7 +393,7 @@ browser_info_remove (GimpModuleDB *db,
while (gtk_tree_model_iter_next (GTK_TREE_MODEL (browser->list), &iter));
g_warning ("%s: Tried to remove a module not in the browser's list.",
G_STRLOC);
G_STRFUNC);
}
static void
......
......@@ -101,7 +101,7 @@ offset_dialog_new (GimpDrawable *drawable,
else if (GIMP_IS_CHANNEL (drawable))
title = _("Offset Channel");
else
g_warning ("%s: unexpected drawable type", G_STRLOC);
g_warning ("%s: unexpected drawable type", G_STRFUNC);
off_d->dlg = gimp_viewable_dialog_new (GIMP_VIEWABLE (drawable),
_("Offset"), "gimp-drawable-offset",
......
......@@ -63,7 +63,7 @@ gimp_display_connect (GimpDisplay *gdisp,
#if 0
g_print ("%s: gimage->ref_count before refing: %d\n",
G_GNUC_FUNCTION, G_OBJECT (gdisp->gimage)->ref_count);
G_STRFUNC, G_OBJECT (gdisp->gimage)->ref_count);
#endif
g_object_ref (gimage);
......@@ -101,7 +101,7 @@ gimp_display_disconnect (GimpDisplay *gdisp)
#if 0
g_print ("%s: gimage->ref_count before unrefing: %d\n",
G_GNUC_FUNCTION, G_OBJECT (gdisp->gimage)->ref_count);
G_STRFUNC, G_OBJECT (gdisp->gimage)->ref_count);
#endif
/* set gdisp->gimage to NULL before unrefing because there may be code
......
......@@ -453,7 +453,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
if (! canvas->window)
{
g_warning ("%s: called unrealized", G_STRLOC);
g_warning ("%s: called unrealized", G_STRFUNC);
return FALSE;
}
......@@ -791,7 +791,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
if (shell->space_release_pending)
{
#ifdef DEBUG_MOVE_PUSH
g_printerr ("%s: popping move tool\n", G_GNUC_FUNCTION);
g_printerr ("%s: popping move tool\n", G_STRFUNC);
#endif
gimp_context_set_tool (gimp_get_user_context (gimp),
......@@ -1103,7 +1103,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
if (GIMP_IS_TOOL_INFO (move_tool_info))
{
#ifdef DEBUG_MOVE_PUSH
g_printerr ("%s: pushing move tool\n", G_GNUC_FUNCTION);
g_printerr ("%s: pushing move tool\n", G_STRFUNC);
#endif
space_shaded_tool = active_tool->tool_info;
......@@ -1190,7 +1190,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
if (shell->space_pressed)
{
#ifdef DEBUG_MOVE_PUSH
g_printerr ("%s: popping move tool\n", G_GNUC_FUNCTION);
g_printerr ("%s: popping move tool\n", G_STRFUNC);
#endif
gimp_context_set_tool (gimp_get_user_context (gimp),
......
Supports Markdown
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