[gimp] app/libgimp*: remove stuff found by -Wunused-but-set-variable
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] app/libgimp*: remove stuff found by -Wunused-but-set-variable
- Date: Sun, 1 May 2011 21:24:17 +0000 (UTC)
commit c35ff719a70637051bb2ddda8028dd17d1e32797
Author: Michael Natterer <mitch gimp org>
Date: Sun May 1 23:23:19 2011 +0200
app/libgimp*: remove stuff found by -Wunused-but-set-variable
app/actions/drawable-actions.c | 2 -
app/actions/image-actions.c | 2 -
app/actions/vectors-actions.c | 2 -
app/config/gimprc-serialize.c | 9 +--
app/core/gimpbrush-load.c | 7 +-
app/core/gimpbrushpipe.c | 7 +--
app/core/gimpbuffer.c | 4 -
app/core/gimpchannelpropundo.c | 2 -
app/core/gimpcurve-save.c | 4 +-
app/core/gimpdrawable-bucket-fill.c | 3 -
app/core/gimpdrawable-transform.c | 3 -
app/core/gimpdrawable.c | 6 +-
app/core/gimplayerpropundo.c | 2 -
app/core/gimpundo.c | 4 -
app/dialogs/fade-dialog.c | 7 +-
app/display/gimpdisplayshell-scale.c | 18 +-----
app/display/gimpimagewindow.c | 27 +++----
app/paint-funcs/paint-funcs-generic.h | 3 -
app/paint/gimppaintcore-stroke.c | 3 -
app/paint/gimpsmudge.c | 3 -
app/tools/gimpimagemaptool.c | 3 -
app/tools/gimpiscissorstool.c | 4 +-
app/tools/gimprectangleselecttool.c | 4 -
app/tools/gimprectangletool.c | 117 ++++++++++---------------------
app/vectors/gimpbezierstroke.c | 25 ++-----
app/vectors/gimpvectorspropundo.c | 6 +-
app/widgets/gimpdockbook.c | 29 +++-----
app/widgets/gimpdynamicseditor.c | 29 ++++----
app/widgets/gimpdynamicsfactoryview.c | 3 -
app/widgets/gimpitemtreeview.c | 7 +--
app/widgets/gimpoverlaydialog.c | 4 +-
app/widgets/gimppaletteeditor.c | 3 -
app/widgets/gimptagentry.c | 14 +----
app/widgets/gimptemplateview.c | 2 -
app/widgets/gimptoolpresetfactoryview.c | 3 -
app/widgets/gtkhwrapbox.c | 4 -
app/xcf/xcf-load.c | 3 -
libgimp/gimpzoompreview.c | 13 ++--
libgimpwidgets/gimpcolornotebook.c | 5 +-
libgimpwidgets/gimppageselector.c | 5 --
40 files changed, 112 insertions(+), 289 deletions(-)
---
diff --git a/app/actions/drawable-actions.c b/app/actions/drawable-actions.c
index 0b835a9..4372271 100644
--- a/app/actions/drawable-actions.c
+++ b/app/actions/drawable-actions.c
@@ -167,7 +167,6 @@ drawable_actions_update (GimpActionGroup *group,
GimpImage *image;
GimpDrawable *drawable = NULL;
gboolean is_rgb = FALSE;
- gboolean is_gray = FALSE;
gboolean is_indexed = FALSE;
gboolean visible = FALSE;
gboolean linked = FALSE;
@@ -188,7 +187,6 @@ drawable_actions_update (GimpActionGroup *group,
GimpItem *item;
is_rgb = GIMP_IMAGE_TYPE_IS_RGB (drawable_type);
- is_gray = GIMP_IMAGE_TYPE_IS_GRAY (drawable_type);
is_indexed = GIMP_IMAGE_TYPE_IS_INDEXED (drawable_type);
if (GIMP_IS_LAYER_MASK (drawable))
diff --git a/app/actions/image-actions.c b/app/actions/image-actions.c
index 37ad96e..1e61d80 100644
--- a/app/actions/image-actions.c
+++ b/app/actions/image-actions.c
@@ -229,7 +229,6 @@ image_actions_update (GimpActionGroup *group,
gpointer data)
{
GimpImage *image = action_data_get_image (data);
- gboolean fs = FALSE;
gboolean aux = FALSE;
gboolean lp = FALSE;
gboolean sel = FALSE;
@@ -257,7 +256,6 @@ image_actions_update (GimpActionGroup *group,
gimp_action_group_set_action_active (group, action, TRUE);
- fs = (gimp_image_get_floating_selection (image) != NULL);
aux = (gimp_image_get_active_channel (image) != NULL);
lp = ! gimp_image_is_empty (image);
sel = ! gimp_channel_is_empty (gimp_image_get_mask (image));
diff --git a/app/actions/vectors-actions.c b/app/actions/vectors-actions.c
index 48b0c89..aad41ce 100644
--- a/app/actions/vectors-actions.c
+++ b/app/actions/vectors-actions.c
@@ -248,7 +248,6 @@ vectors_actions_update (GimpActionGroup *group,
GimpDrawable *drawable = NULL;
gint n_vectors = 0;
gboolean mask_empty = TRUE;
- gboolean global_buf = FALSE;
gboolean visible = FALSE;
gboolean linked = FALSE;
gboolean locked = FALSE;
@@ -262,7 +261,6 @@ vectors_actions_update (GimpActionGroup *group,
{
n_vectors = gimp_image_get_n_vectors (image);
mask_empty = gimp_channel_is_empty (gimp_image_get_mask (image));
- global_buf = FALSE;
vectors = gimp_image_get_active_vectors (image);
diff --git a/app/config/gimprc-serialize.c b/app/config/gimprc-serialize.c
index 970bea3..52bf900 100644
--- a/app/config/gimprc-serialize.c
+++ b/app/config/gimprc-serialize.c
@@ -63,18 +63,15 @@ gimp_rc_serialize_properties_diff (GimpConfig *config,
GimpConfig *compare,
GimpConfigWriter *writer)
{
- GObjectClass *klass;
- GList *diff;
- GList *list;
- gboolean retval = TRUE;
+ GList *diff;
+ GList *list;
+ gboolean retval = TRUE;
g_return_val_if_fail (G_IS_OBJECT (config), FALSE);
g_return_val_if_fail (G_IS_OBJECT (compare), FALSE);
g_return_val_if_fail (G_TYPE_FROM_INSTANCE (config) ==
G_TYPE_FROM_INSTANCE (compare), FALSE);
- klass = G_OBJECT_GET_CLASS (config);
-
diff = gimp_config_diff (G_OBJECT (config),
G_OBJECT (compare), GIMP_CONFIG_PARAM_SERIALIZE);
diff --git a/app/core/gimpbrush-load.c b/app/core/gimpbrush-load.c
index 56368a8..a032428 100644
--- a/app/core/gimpbrush-load.c
+++ b/app/core/gimpbrush-load.c
@@ -688,7 +688,6 @@ gimp_brush_load_abr_brush_v6 (FILE *file,
gint32 brush_size;
gint32 brush_end;
- gint32 complement_to_4;
gint32 next_brush;
gint32 top, left, bottom, right;
@@ -704,9 +703,11 @@ gimp_brush_load_abr_brush_v6 (FILE *file,
brush_size = abr_read_long (file);
brush_end = brush_size;
+
/* complement to 4 */
- while (brush_end % 4 != 0) brush_end++;
- complement_to_4 = brush_end - brush_size;
+ while (brush_end % 4 != 0)
+ brush_end++;
+
next_brush = ftell (file) + brush_end;
if (abr_hdr->count == 1)
diff --git a/app/core/gimpbrushpipe.c b/app/core/gimpbrushpipe.c
index d76a8c5..e0d5b40 100644
--- a/app/core/gimpbrushpipe.c
+++ b/app/core/gimpbrushpipe.c
@@ -199,16 +199,11 @@ gimp_brush_pipe_select_brush (GimpBrush *brush,
{
GimpBrushPipe *pipe = GIMP_BRUSH_PIPE (brush);
gint i, brushix, ix;
- gdouble velocity, spacing;
+ gdouble velocity;
if (pipe->n_brushes == 1)
return GIMP_BRUSH (pipe->current);
-
- /* calculates brush native spacing in pixels, based on it's width)*/
- spacing = ((gdouble) gimp_brush_get_spacing (pipe->current) / 100) *
- MAX (brush->mask->width, brush->mask->height);
-
brushix = 0;
for (i = 0; i < pipe->dimension; i++)
{
diff --git a/app/core/gimpbuffer.c b/app/core/gimpbuffer.c
index cec9a01..7988634 100644
--- a/app/core/gimpbuffer.c
+++ b/app/core/gimpbuffer.c
@@ -221,14 +221,10 @@ gimp_buffer_new (TileManager *tiles,
gboolean copy_pixels)
{
GimpBuffer *buffer;
- gint width, height;
g_return_val_if_fail (tiles != NULL, NULL);
g_return_val_if_fail (name != NULL, NULL);
- width = tile_manager_width (tiles);
- height = tile_manager_height (tiles);
-
buffer = g_object_new (GIMP_TYPE_BUFFER,
"name", name,
NULL);
diff --git a/app/core/gimpchannelpropundo.c b/app/core/gimpchannelpropundo.c
index 9400df3..8ec07d3 100644
--- a/app/core/gimpchannelpropundo.c
+++ b/app/core/gimpchannelpropundo.c
@@ -60,7 +60,6 @@ static void
gimp_channel_prop_undo_constructed (GObject *object)
{
GimpChannelPropUndo *channel_prop_undo = GIMP_CHANNEL_PROP_UNDO (object);
- GimpImage *image;
GimpChannel *channel;
if (G_OBJECT_CLASS (parent_class)->constructed)
@@ -68,7 +67,6 @@ gimp_channel_prop_undo_constructed (GObject *object)
g_assert (GIMP_IS_CHANNEL (GIMP_ITEM_UNDO (object)->item));
- image = GIMP_UNDO (object)->image;
channel = GIMP_CHANNEL (GIMP_ITEM_UNDO (object)->item);
switch (GIMP_UNDO (object)->undo_type)
diff --git a/app/core/gimpcurve-save.c b/app/core/gimpcurve-save.c
index 0313080..b7925f3 100644
--- a/app/core/gimpcurve-save.c
+++ b/app/core/gimpcurve-save.c
@@ -36,13 +36,13 @@ gboolean
gimp_curve_save (GimpData *data,
GError **error)
{
- GimpCurve *curve;
+ /* GimpCurve *curve; */
FILE *file;
g_return_val_if_fail (GIMP_IS_CURVE (data), FALSE);
g_return_val_if_fail (error == NULL || *error == NULL, FALSE);
- curve = GIMP_CURVE (data);
+ /* curve = GIMP_CURVE (data); */
file = g_fopen (gimp_data_get_filename (data), "wb");
diff --git a/app/core/gimpdrawable-bucket-fill.c b/app/core/gimpdrawable-bucket-fill.c
index 30f2ebf..4995c46 100644
--- a/app/core/gimpdrawable-bucket-fill.c
+++ b/app/core/gimpdrawable-bucket-fill.c
@@ -63,7 +63,6 @@ gimp_drawable_bucket_fill (GimpDrawable *drawable,
gdouble y,
GError **error)
{
- GimpImage *image;
GimpRGB color;
GimpPattern *pattern = NULL;
@@ -72,8 +71,6 @@ gimp_drawable_bucket_fill (GimpDrawable *drawable,
g_return_val_if_fail (GIMP_IS_CONTEXT (context), FALSE);
g_return_val_if_fail (error == NULL || *error == NULL, FALSE);
- image = gimp_item_get_image (GIMP_ITEM (drawable));
-
if (fill_mode == GIMP_FG_BUCKET_FILL)
{
gimp_context_get_foreground (context, &color);
diff --git a/app/core/gimpdrawable-transform.c b/app/core/gimpdrawable-transform.c
index dc13147..65f2352 100644
--- a/app/core/gimpdrawable-transform.c
+++ b/app/core/gimpdrawable-transform.c
@@ -78,7 +78,6 @@ gimp_drawable_transform_tiles_affine (GimpDrawable *drawable,
gint *new_offset_y,
GimpProgress *progress)
{
- GimpImage *image;
PixelRegion destPR;
TileManager *new_tiles;
GimpMatrix3 m;
@@ -95,8 +94,6 @@ gimp_drawable_transform_tiles_affine (GimpDrawable *drawable,
g_return_val_if_fail (new_offset_y != NULL, NULL);
g_return_val_if_fail (progress == NULL || GIMP_IS_PROGRESS (progress), NULL);
- image = gimp_item_get_image (GIMP_ITEM (drawable));
-
m = *matrix;
inv = *matrix;
diff --git a/app/core/gimpdrawable.c b/app/core/gimpdrawable.c
index 6207b0c..f2f8edc 100644
--- a/app/core/gimpdrawable.c
+++ b/app/core/gimpdrawable.c
@@ -1482,15 +1482,13 @@ gimp_drawable_set_tiles_full (GimpDrawable *drawable,
gint offset_x,
gint offset_y)
{
- GimpItem *item;
- GimpImage *image;
+ GimpItem *item;
g_return_if_fail (GIMP_IS_DRAWABLE (drawable));
g_return_if_fail (tiles != NULL);
g_return_if_fail (tile_manager_bpp (tiles) == GIMP_IMAGE_TYPE_BYTES (type));
- item = GIMP_ITEM (drawable);
- image = gimp_item_get_image (item);
+ item = GIMP_ITEM (drawable);
if (! gimp_item_is_attached (GIMP_ITEM (drawable)))
push_undo = FALSE;
diff --git a/app/core/gimplayerpropundo.c b/app/core/gimplayerpropundo.c
index d27876c..636c9ab 100644
--- a/app/core/gimplayerpropundo.c
+++ b/app/core/gimplayerpropundo.c
@@ -60,7 +60,6 @@ static void
gimp_layer_prop_undo_constructed (GObject *object)
{
GimpLayerPropUndo *layer_prop_undo = GIMP_LAYER_PROP_UNDO (object);
- GimpImage *image;
GimpLayer *layer;
if (G_OBJECT_CLASS (parent_class)->constructed)
@@ -68,7 +67,6 @@ gimp_layer_prop_undo_constructed (GObject *object)
g_assert (GIMP_IS_LAYER (GIMP_ITEM_UNDO (object)->item));
- image = GIMP_UNDO (object)->image;
layer = GIMP_LAYER (GIMP_ITEM_UNDO (object)->item);
switch (GIMP_UNDO (object)->undo_type)
diff --git a/app/core/gimpundo.c b/app/core/gimpundo.c
index 79af2d7..e4e7317 100644
--- a/app/core/gimpundo.c
+++ b/app/core/gimpundo.c
@@ -530,13 +530,9 @@ gimp_undo_type_to_name (GimpUndoType type)
gboolean
gimp_undo_is_weak (GimpUndo *undo)
{
- GimpUndoType type;
-
if (! undo)
return FALSE;
- type = undo->undo_type;
-
switch (undo->undo_type)
{
case GIMP_UNDO_GROUP_ITEM_VISIBILITY:
diff --git a/app/dialogs/fade-dialog.c b/app/dialogs/fade-dialog.c
index b5bac00..e1881a0 100644
--- a/app/dialogs/fade-dialog.c
+++ b/app/dialogs/fade-dialog.c
@@ -77,7 +77,6 @@ fade_dialog_new (GimpImage *image,
GtkWidget *main_vbox;
GtkWidget *table;
GtkWidget *menu;
- GtkWidget *label;
gchar *title;
gint table_row = 0;
@@ -153,9 +152,9 @@ fade_dialog_new (GimpImage *image,
/* the paint mode menu */
menu = gimp_prop_paint_mode_menu_new (G_OBJECT (private->context),
"paint-mode", TRUE, TRUE);
- label = gimp_table_attach_aligned (GTK_TABLE (table), 0, table_row++,
- _("_Mode:"), 0.0, 0.5,
- menu, 2, FALSE);
+ gimp_table_attach_aligned (GTK_TABLE (table), 0, table_row++,
+ _("_Mode:"), 0.0, 0.5,
+ menu, 2, FALSE);
/* the opacity scale */
gimp_prop_opacity_entry_new (G_OBJECT (private->context), "opacity",
diff --git a/app/display/gimpdisplayshell-scale.c b/app/display/gimpdisplayshell-scale.c
index 63b0dd6..5543527 100644
--- a/app/display/gimpdisplayshell-scale.c
+++ b/app/display/gimpdisplayshell-scale.c
@@ -107,27 +107,11 @@ gimp_display_shell_update_scrollbars_and_rulers (GimpDisplayShell *shell)
void
gimp_display_shell_scale_update_scrollbars (GimpDisplayShell *shell)
{
- GimpImage *image;
- gint image_width;
- gint image_height;
+ g_return_if_fail (GIMP_IS_DISPLAY_SHELL (shell));
if (! shell->display)
return;
- image = gimp_display_get_image (shell->display);
-
- if (image)
- {
- image_width = gimp_image_get_width (image);
- image_height = gimp_image_get_height (image);
- }
- else
- {
- image_width = shell->disp_width;
- image_height = shell->disp_height;
- }
-
-
/* Horizontal scrollbar */
g_object_freeze_notify (G_OBJECT (shell->hsbdata));
diff --git a/app/display/gimpimagewindow.c b/app/display/gimpimagewindow.c
index 953f92f..c70be69 100644
--- a/app/display/gimpimagewindow.c
+++ b/app/display/gimpimagewindow.c
@@ -904,24 +904,21 @@ void
gimp_image_window_shrink_wrap (GimpImageWindow *window,
gboolean grow_only)
{
- GimpImageWindowPrivate *private;
- GimpDisplayShell *active_shell;
- GimpImage *image;
- GtkWidget *widget;
- GtkAllocation allocation;
- GdkScreen *screen;
- GdkRectangle rect;
- gint monitor;
- gint disp_width, disp_height;
- gint width, height;
- gint max_auto_width, max_auto_height;
- gint border_width, border_height;
- gboolean resize = FALSE;
+ GimpDisplayShell *active_shell;
+ GimpImage *image;
+ GtkWidget *widget;
+ GtkAllocation allocation;
+ GdkScreen *screen;
+ GdkRectangle rect;
+ gint monitor;
+ gint disp_width, disp_height;
+ gint width, height;
+ gint max_auto_width, max_auto_height;
+ gint border_width, border_height;
+ gboolean resize = FALSE;
g_return_if_fail (GIMP_IS_IMAGE_WINDOW (window));
- private = GIMP_IMAGE_WINDOW_GET_PRIVATE (window);
-
if (! gtk_widget_get_realized (GTK_WIDGET (window)))
return;
diff --git a/app/paint-funcs/paint-funcs-generic.h b/app/paint-funcs/paint-funcs-generic.h
index 183f862..401b867 100644
--- a/app/paint-funcs/paint-funcs-generic.h
+++ b/app/paint-funcs/paint-funcs-generic.h
@@ -127,9 +127,6 @@ color_pixels_mask (guchar *dest,
guint bytes)
{
guchar c0, c1, c2;
- gint alpha;
-
- alpha = HAS_ALPHA (bytes) ? bytes - 1 : bytes;
switch (bytes)
{
diff --git a/app/paint/gimppaintcore-stroke.c b/app/paint/gimppaintcore-stroke.c
index ff396d5..7c1a8f3 100644
--- a/app/paint/gimppaintcore-stroke.c
+++ b/app/paint/gimppaintcore-stroke.c
@@ -108,7 +108,6 @@ gimp_paint_core_stroke_boundary (GimpPaintCore *core,
gboolean push_undo,
GError **error)
{
- GimpImage *image;
BoundSeg *stroke_segs;
gint n_stroke_segs;
gint off_x;
@@ -126,8 +125,6 @@ gimp_paint_core_stroke_boundary (GimpPaintCore *core,
g_return_val_if_fail (bound_segs != NULL && n_bound_segs > 0, FALSE);
g_return_val_if_fail (error == NULL || *error == NULL, FALSE);
- image = gimp_item_get_image (GIMP_ITEM (drawable));
-
stroke_segs = boundary_sort (bound_segs, n_bound_segs, &n_stroke_segs);
if (n_stroke_segs == 0)
diff --git a/app/paint/gimpsmudge.c b/app/paint/gimpsmudge.c
index 392e19e..7c6c7ec 100644
--- a/app/paint/gimpsmudge.c
+++ b/app/paint/gimpsmudge.c
@@ -163,14 +163,11 @@ gimp_smudge_start (GimpPaintCore *paint_core,
const GimpCoords *coords)
{
GimpSmudge *smudge = GIMP_SMUDGE (paint_core);
- GimpImage *image;
TempBuf *area;
PixelRegion srcPR;
gint bytes;
gint x, y, w, h;
- image = gimp_item_get_image (GIMP_ITEM (drawable));
-
if (gimp_drawable_is_indexed (drawable))
return FALSE;
diff --git a/app/tools/gimpimagemaptool.c b/app/tools/gimpimagemaptool.c
index 74d7533..ca29fcd 100644
--- a/app/tools/gimpimagemaptool.c
+++ b/app/tools/gimpimagemaptool.c
@@ -298,12 +298,9 @@ gimp_image_map_tool_initialize (GimpTool *tool,
GtkWidget *dialog;
GtkWidget *vbox;
GtkWidget *toggle;
- const gchar *stock_id;
klass = GIMP_IMAGE_MAP_TOOL_GET_CLASS (image_map_tool);
- stock_id = gimp_viewable_get_stock_id (GIMP_VIEWABLE (tool_info));
-
window = gimp_display_shell_get_window (display_shell);
image_map_tool->overlay = gimp_image_window_get_fullscreen (window);
diff --git a/app/tools/gimpiscissorstool.c b/app/tools/gimpiscissorstool.c
index 8dac046..8392fea 100644
--- a/app/tools/gimpiscissorstool.c
+++ b/app/tools/gimpiscissorstool.c
@@ -1812,7 +1812,7 @@ find_max_gradient (GimpIscissorsTool *iscissors,
gint radius;
gint i, j;
gint endx, endy;
- gint sx, sy, cx, cy;
+ gint cx, cy;
gint x1, y1, x2, y2;
gpointer pr;
gfloat max_gradient;
@@ -1827,8 +1827,6 @@ find_max_gradient (GimpIscissorsTool *iscissors,
/* calculate the extent of the search */
cx = CLAMP (*x, 0, gimp_image_get_width (image));
cy = CLAMP (*y, 0, gimp_image_get_height (image));
- sx = cx - radius;
- sy = cy - radius;
x1 = CLAMP (cx - radius, 0, gimp_image_get_width (image));
y1 = CLAMP (cy - radius, 0, gimp_image_get_height (image));
x2 = CLAMP (cx + radius, 0, gimp_image_get_width (image));
diff --git a/app/tools/gimprectangleselecttool.c b/app/tools/gimprectangleselecttool.c
index ffcdc40..4d7c087 100644
--- a/app/tools/gimprectangleselecttool.c
+++ b/app/tools/gimprectangleselecttool.c
@@ -556,12 +556,8 @@ gimp_rectangle_select_tool_oper_update (GimpTool *tool,
gboolean proximity,
GimpDisplay *display)
{
- GimpRectangleFunction function;
-
gimp_rectangle_tool_oper_update (tool, coords, state, proximity, display);
- function = gimp_rectangle_tool_get_function (GIMP_RECTANGLE_TOOL (tool));
-
GIMP_TOOL_CLASS (parent_class)->oper_update (tool, coords, state, proximity,
display);
}
diff --git a/app/tools/gimprectangletool.c b/app/tools/gimprectangletool.c
index a32ca53..efb0357 100644
--- a/app/tools/gimprectangletool.c
+++ b/app/tools/gimprectangletool.c
@@ -897,21 +897,17 @@ gimp_rectangle_tool_button_press (GimpTool *tool,
GdkModifierType state,
GimpDisplay *display)
{
- GimpRectangleTool *rect_tool;
- GimpDrawTool *draw_tool;
- GimpRectangleToolPrivate *private;
- GimpRectangleOptions *options;
- GimpRectangleOptionsPrivate *options_private;
- gdouble snapped_x, snapped_y;
- gint snap_x, snap_y;
+ GimpRectangleTool *rect_tool;
+ GimpDrawTool *draw_tool;
+ GimpRectangleToolPrivate *private;
+ gdouble snapped_x, snapped_y;
+ gint snap_x, snap_y;
g_return_if_fail (GIMP_IS_RECTANGLE_TOOL (tool));
- rect_tool = GIMP_RECTANGLE_TOOL (tool);
- draw_tool = GIMP_DRAW_TOOL (tool);
- private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (tool);
- options = GIMP_RECTANGLE_TOOL_GET_OPTIONS (tool);
- options_private = GIMP_RECTANGLE_OPTIONS_GET_PRIVATE (options);
+ rect_tool = GIMP_RECTANGLE_TOOL (tool);
+ draw_tool = GIMP_DRAW_TOOL (tool);
+ private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (tool);
gimp_draw_tool_pause (draw_tool);
@@ -1019,13 +1015,11 @@ gimp_rectangle_tool_button_release (GimpTool *tool,
{
GimpRectangleTool *rect_tool;
GimpRectangleToolPrivate *private;
- GimpRectangleOptions *options;
g_return_if_fail (GIMP_IS_RECTANGLE_TOOL (tool));
rect_tool = GIMP_RECTANGLE_TOOL (tool);
private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (tool);
- options = GIMP_RECTANGLE_TOOL_GET_OPTIONS (tool);
gimp_draw_tool_pause (GIMP_DRAW_TOOL (tool));
@@ -1093,20 +1087,18 @@ gimp_rectangle_tool_motion (GimpTool *tool,
GdkModifierType state,
GimpDisplay *display)
{
- GimpRectangleTool *rect_tool;
- GimpRectangleToolPrivate *private;
- GimpRectangleOptions *options;
- GimpRectangleOptionsPrivate *options_private;
- gdouble snapped_x;
- gdouble snapped_y;
- gint snap_x, snap_y;
+ GimpRectangleTool *rect_tool;
+ GimpRectangleToolPrivate *private;
+ GimpRectangleOptions *options;
+ gdouble snapped_x;
+ gdouble snapped_y;
+ gint snap_x, snap_y;
g_return_if_fail (GIMP_IS_RECTANGLE_TOOL (tool));
- rect_tool = GIMP_RECTANGLE_TOOL (tool);
- private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (tool);
- options = GIMP_RECTANGLE_TOOL_GET_OPTIONS (tool);
- options_private = GIMP_RECTANGLE_OPTIONS_GET_PRIVATE (options);
+ rect_tool = GIMP_RECTANGLE_TOOL (tool);
+ private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (tool);
+ options = GIMP_RECTANGLE_TOOL_GET_OPTIONS (tool);
/* Motion events should be ignored when we're just waiting for the
* button release event to execute or if the user has grabbed a dead
@@ -1668,15 +1660,13 @@ gimp_rectangle_tool_cursor_update (GimpTool *tool,
GdkModifierType state,
GimpDisplay *display)
{
- GimpRectangleTool *rect_tool;
GimpRectangleToolPrivate *private;
GimpCursorType cursor = GIMP_CURSOR_CROSSHAIR_SMALL;
GimpCursorModifier modifier = GIMP_CURSOR_MODIFIER_NONE;
g_return_if_fail (GIMP_IS_RECTANGLE_TOOL (tool));
- rect_tool = GIMP_RECTANGLE_TOOL (tool);
- private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (tool);
+ private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (tool);
if (tool->display == display)
{
@@ -2132,7 +2122,6 @@ gimp_rectangle_tool_start (GimpRectangleTool *rect_tool,
{
GimpTool *tool = GIMP_TOOL (rect_tool);
GimpRectangleOptionsPrivate *options_private;
- GimpRectangleToolPrivate *private;
GimpImage *image;
gdouble xres;
gdouble yres;
@@ -2140,8 +2129,6 @@ gimp_rectangle_tool_start (GimpRectangleTool *rect_tool,
options_private =
GIMP_RECTANGLE_OPTIONS_GET_PRIVATE (gimp_tool_get_options (tool));
- private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (rect_tool);
-
image = gimp_display_get_image (display);
tool->display = display;
@@ -2277,15 +2264,12 @@ gimp_rectangle_tool_execute (GimpRectangleTool *rect_tool)
if (iface->execute)
{
- GimpRectangleToolPrivate *private;
- gdouble pub_x1, pub_y1;
- gdouble pub_x2, pub_y2;
+ gdouble pub_x1, pub_y1;
+ gdouble pub_x2, pub_y2;
gimp_rectangle_tool_get_public_rect (rect_tool,
&pub_x1, &pub_y1, &pub_x2, &pub_y2);
- private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (rect_tool);
-
gimp_draw_tool_pause (GIMP_DRAW_TOOL (rect_tool));
retval = iface->execute (rect_tool,
@@ -2317,16 +2301,14 @@ static void
gimp_rectangle_tool_update_options (GimpRectangleTool *rect_tool,
GimpDisplay *display)
{
- GimpRectangleToolPrivate *private;
- GimpRectangleOptions *options;
- gdouble x1, y1;
- gdouble x2, y2;
- gdouble old_x;
- gdouble old_y;
- gdouble old_width;
- gdouble old_height;
+ GimpRectangleOptions *options;
+ gdouble x1, y1;
+ gdouble x2, y2;
+ gdouble old_x;
+ gdouble old_y;
+ gdouble old_width;
+ gdouble old_height;
- private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (rect_tool);
options = GIMP_RECTANGLE_TOOL_GET_OPTIONS (rect_tool);
gimp_rectangle_tool_get_public_rect (rect_tool, &x1, &y1, &x2, &y2);
@@ -2960,12 +2942,9 @@ gimp_rectangle_tool_update_highlight (GimpRectangleTool *rect_tool)
}
else
{
- GimpRectangleToolPrivate *private;
- GdkRectangle rect;
- gdouble pub_x1, pub_y1;
- gdouble pub_x2, pub_y2;
-
- private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (tool);
+ GdkRectangle rect;
+ gdouble pub_x1, pub_y1;
+ gdouble pub_x2, pub_y2;
gimp_rectangle_tool_get_public_rect (rect_tool,
&pub_x1, &pub_y1, &pub_x2, &pub_y2);
@@ -3100,14 +3079,8 @@ gimp_rectangle_tool_get_other_side_coord (GimpRectangleTool *rect_tool,
gdouble *other_side_x,
gdouble *other_side_y)
{
- GimpRectangleToolPrivate *private;
- gdouble *other_x;
- gdouble *other_y;
-
- private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (rect_tool);
-
- other_x = NULL;
- other_y = NULL;
+ gdouble *other_x = NULL;
+ gdouble *other_y = NULL;
gimp_rectangle_tool_get_other_side (rect_tool,
&other_x,
@@ -3123,14 +3096,8 @@ gimp_rectangle_tool_set_other_side_coord (GimpRectangleTool *rect_tool,
gdouble other_side_x,
gdouble other_side_y)
{
- GimpRectangleToolPrivate *private;
- gdouble *other_x;
- gdouble *other_y;
-
- private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (rect_tool);
-
- other_x = NULL;
- other_y = NULL;
+ gdouble *other_x = NULL;
+ gdouble *other_y = NULL;
gimp_rectangle_tool_get_other_side (rect_tool,
&other_x,
@@ -3628,13 +3595,9 @@ gimp_rectangle_tool_apply_fixed_width (GimpRectangleTool *rect_tool,
GimpRectangleConstraint constraint,
gdouble width)
{
- GimpRectangleToolPrivate *private;
- GimpRectangleOptions *options;
- GimpRectangleOptionsPrivate *options_private;
+ GimpRectangleToolPrivate *private;
- private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (rect_tool);
- options = GIMP_RECTANGLE_TOOL_GET_OPTIONS (rect_tool);
- options_private = GIMP_RECTANGLE_OPTIONS_GET_PRIVATE (options);
+ private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (rect_tool);
switch (private->function)
{
@@ -3688,13 +3651,9 @@ gimp_rectangle_tool_apply_fixed_height (GimpRectangleTool *rect_tool,
gdouble height)
{
- GimpRectangleToolPrivate *private;
- GimpRectangleOptions *options;
- GimpRectangleOptionsPrivate *options_private;
+ GimpRectangleToolPrivate *private;
- private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (rect_tool);
- options = GIMP_RECTANGLE_TOOL_GET_OPTIONS (rect_tool);
- options_private = GIMP_RECTANGLE_OPTIONS_GET_PRIVATE (options);
+ private = GIMP_RECTANGLE_TOOL_GET_PRIVATE (rect_tool);
switch (private->function)
{
diff --git a/app/vectors/gimpbezierstroke.c b/app/vectors/gimpbezierstroke.c
index 4dc0c77..b7699de 100644
--- a/app/vectors/gimpbezierstroke.c
+++ b/app/vectors/gimpbezierstroke.c
@@ -202,10 +202,9 @@ gimp_bezier_stroke_new_from_coords (const GimpCoords *coords,
gint n_coords,
gboolean closed)
{
- GimpBezierStroke *bezier_stroke;
- GimpStroke *stroke;
- GimpAnchor *last_anchor;
- gint count;
+ GimpStroke *stroke;
+ GimpAnchor *last_anchor;
+ gint count;
g_return_val_if_fail (coords != NULL, NULL);
g_return_val_if_fail (n_coords >= 3, NULL);
@@ -213,8 +212,6 @@ gimp_bezier_stroke_new_from_coords (const GimpCoords *coords,
stroke = gimp_bezier_stroke_new ();
- bezier_stroke = GIMP_BEZIER_STROKE (stroke);
-
last_anchor = NULL;
for (count = 0; count < n_coords; count++)
@@ -990,11 +987,8 @@ static gboolean
gimp_bezier_stroke_is_extendable (GimpStroke *stroke,
GimpAnchor *neighbor)
{
- GimpBezierStroke *bezier_stroke;
- GList *listneighbor;
- gint loose_end;
-
- bezier_stroke = GIMP_BEZIER_STROKE (stroke);
+ GList *listneighbor;
+ gint loose_end;
if (stroke->closed)
return FALSE;
@@ -1079,12 +1073,9 @@ gimp_bezier_stroke_extend (GimpStroke *stroke,
GimpAnchor *neighbor,
GimpVectorExtendMode extend_mode)
{
- GimpAnchor *anchor = NULL;
- GimpBezierStroke *bezier_stroke;
- GList *listneighbor;
- gint loose_end, control_count;
-
- bezier_stroke = GIMP_BEZIER_STROKE (stroke);
+ GimpAnchor *anchor = NULL;
+ GList *listneighbor;
+ gint loose_end, control_count;
if (stroke->anchors == NULL)
{
diff --git a/app/vectors/gimpvectorspropundo.c b/app/vectors/gimpvectorspropundo.c
index a2c9fc4..43992bf 100644
--- a/app/vectors/gimpvectorspropundo.c
+++ b/app/vectors/gimpvectorspropundo.c
@@ -58,16 +58,14 @@ gimp_vectors_prop_undo_init (GimpVectorsPropUndo *undo)
static void
gimp_vectors_prop_undo_constructed (GObject *object)
{
- GimpImage *image;
- GimpVectors *vectors;
+ /* GimpVectors *vectors; */
if (G_OBJECT_CLASS (parent_class)->constructed)
G_OBJECT_CLASS (parent_class)->constructed (object);
g_assert (GIMP_IS_VECTORS (GIMP_ITEM_UNDO (object)->item));
- image = GIMP_UNDO (object)->image;
- vectors = GIMP_VECTORS (GIMP_ITEM_UNDO (object)->item);
+ /* vectors = GIMP_VECTORS (GIMP_ITEM_UNDO (object)->item); */
switch (GIMP_UNDO (object)->undo_type)
{
diff --git a/app/widgets/gimpdockbook.c b/app/widgets/gimpdockbook.c
index 580c112..0825be0 100644
--- a/app/widgets/gimpdockbook.c
+++ b/app/widgets/gimpdockbook.c
@@ -1311,17 +1311,12 @@ gimp_dockbook_tab_drag_begin (GtkWidget *widget,
GdkDragContext *context,
GimpDockable *dockable)
{
- GimpDock *dock;
- GimpPanedBoxClass *paned_box_class;
- GtkAllocation allocation;
- GtkWidget *window;
- GtkWidget *view;
- GtkRequisition requisition;
- gint drag_x;
- gint drag_y;
-
- dock = GIMP_DOCK (gimp_dockable_get_dockbook (dockable)->p->dock);
- paned_box_class = GIMP_PANED_BOX_GET_CLASS (gimp_dock_get_vbox (dock));
+ GtkAllocation allocation;
+ GtkWidget *window;
+ GtkWidget *view;
+ GtkRequisition requisition;
+ gint drag_x;
+ gint drag_y;
gtk_widget_get_allocation (widget, &allocation);
@@ -1359,14 +1354,10 @@ gimp_dockbook_tab_drag_end (GtkWidget *widget,
GdkDragContext *context,
GimpDockable *dockable)
{
- GimpDock *dock;
- GimpPanedBoxClass *paned_box_class;
- GtkWidget *drag_widget;
-
- dock = GIMP_DOCK (gimp_dockable_get_dockbook (dockable)->p->dock);
- paned_box_class = GIMP_PANED_BOX_GET_CLASS (gimp_dock_get_vbox (dock));
- drag_widget = g_object_get_data (G_OBJECT (dockable),
- "gimp-dock-drag-widget");
+ GtkWidget *drag_widget;
+
+ drag_widget = g_object_get_data (G_OBJECT (dockable),
+ "gimp-dock-drag-widget");
/* finding the drag_widget means the drop was not successful, so
* pop up a new dock and move the dockable there
diff --git a/app/widgets/gimpdynamicseditor.c b/app/widgets/gimpdynamicseditor.c
index 9352dbd..25fe738 100644
--- a/app/widgets/gimpdynamicseditor.c
+++ b/app/widgets/gimpdynamicseditor.c
@@ -305,7 +305,6 @@ gimp_dynamics_editor_add_output_row (GObject *config,
gint row)
{
GtkWidget *label;
- GtkWidget *button;
gint column = 1;
label = gtk_label_new (row_label);
@@ -314,32 +313,32 @@ gimp_dynamics_editor_add_output_row (GObject *config,
GTK_SHRINK | GTK_FILL, GTK_SHRINK | GTK_FILL, 0, 0);
gtk_widget_show (label);
- button = dynamics_check_button_new (config, "use-pressure",
- table, column, row);
+ dynamics_check_button_new (config, "use-pressure",
+ table, column, row);
column++;
- button = dynamics_check_button_new (config, "use-velocity",
- table, column, row);
+ dynamics_check_button_new (config, "use-velocity",
+ table, column, row);
column++;
- button = dynamics_check_button_new (config, "use-direction",
- table, column, row);
+ dynamics_check_button_new (config, "use-direction",
+ table, column, row);
column++;
- button = dynamics_check_button_new (config, "use-tilt",
- table, column, row);
+ dynamics_check_button_new (config, "use-tilt",
+ table, column, row);
column++;
- button = dynamics_check_button_new (config, "use-wheel",
- table, column, row);
+ dynamics_check_button_new (config, "use-wheel",
+ table, column, row);
column++;
- button = dynamics_check_button_new (config, "use-random",
- table, column, row);
+ dynamics_check_button_new (config, "use-random",
+ table, column, row);
column++;
- button = dynamics_check_button_new (config, "use-fade",
- table, column, row);
+ dynamics_check_button_new (config, "use-fade",
+ table, column, row);
column++;
}
diff --git a/app/widgets/gimpdynamicsfactoryview.c b/app/widgets/gimpdynamicsfactoryview.c
index 25e0c5f..2fa0fcb 100644
--- a/app/widgets/gimpdynamicsfactoryview.c
+++ b/app/widgets/gimpdynamicsfactoryview.c
@@ -59,7 +59,6 @@ gimp_dynamics_factory_view_new (GimpViewType view_type,
GimpMenuFactory *menu_factory)
{
GimpDynamicsFactoryView *factory_view;
- GimpContainerEditor *editor;
g_return_val_if_fail (GIMP_IS_DATA_FACTORY (factory), NULL);
g_return_val_if_fail (view_size > 0 &&
@@ -83,7 +82,5 @@ gimp_dynamics_factory_view_new (GimpViewType view_type,
return NULL;
}
- editor = GIMP_CONTAINER_EDITOR (factory_view);
-
return GTK_WIDGET (factory_view);
}
diff --git a/app/widgets/gimpitemtreeview.c b/app/widgets/gimpitemtreeview.c
index 0a0045f..0be6cca 100644
--- a/app/widgets/gimpitemtreeview.c
+++ b/app/widgets/gimpitemtreeview.c
@@ -622,9 +622,8 @@ gimp_item_tree_view_add_options (GimpItemTreeView *view,
const gchar *label,
GtkWidget *options)
{
- gint content_spacing;
- gint button_spacing;
- gboolean box_created = FALSE;
+ gint content_spacing;
+ gint button_spacing;
g_return_if_fail (GIMP_IS_ITEM_TREE_VIEW (view));
g_return_if_fail (GTK_IS_WIDGET (options));
@@ -651,8 +650,6 @@ gimp_item_tree_view_add_options (GimpItemTreeView *view,
{
gtk_widget_set_sensitive (view->priv->options_box, FALSE);
}
-
- box_created = TRUE;
}
if (label)
diff --git a/app/widgets/gimpoverlaydialog.c b/app/widgets/gimpoverlaydialog.c
index 1ef9e07..e34bdff 100644
--- a/app/widgets/gimpoverlaydialog.c
+++ b/app/widgets/gimpoverlaydialog.c
@@ -266,12 +266,12 @@ gimp_overlay_dialog_new (GimpToolInfo *tool_info,
...)
{
GtkWidget *dialog;
- const gchar *stock_id;
+ /* const gchar *stock_id; */
va_list args;
g_return_val_if_fail (GIMP_IS_TOOL_INFO (tool_info), NULL);
- stock_id = gimp_viewable_get_stock_id (GIMP_VIEWABLE (tool_info));
+ /* stock_id = gimp_viewable_get_stock_id (GIMP_VIEWABLE (tool_info)); */
dialog = g_object_new (GIMP_TYPE_OVERLAY_DIALOG, NULL);
diff --git a/app/widgets/gimppaletteeditor.c b/app/widgets/gimppaletteeditor.c
index c7213de..8f90747 100644
--- a/app/widgets/gimppaletteeditor.c
+++ b/app/widgets/gimppaletteeditor.c
@@ -669,9 +669,6 @@ palette_editor_entry_selected (GimpPaletteView *view,
GimpPaletteEditor *editor)
{
GimpDataEditor *data_editor = GIMP_DATA_EDITOR (editor);
- GimpPalette *palette;
-
- palette = GIMP_PALETTE (data_editor->data);
if (editor->color != entry)
{
diff --git a/app/widgets/gimptagentry.c b/app/widgets/gimptagentry.c
index 70e0e8b..3c3b47b 100644
--- a/app/widgets/gimptagentry.c
+++ b/app/widgets/gimptagentry.c
@@ -445,13 +445,11 @@ gimp_tag_entry_insert_text (GtkEditable *editable,
gint *position)
{
GimpTagEntry *entry = GIMP_TAG_ENTRY (editable);
- const gchar *entry_text;
gboolean is_tag[2];
gint i;
gint insert_pos = *position;
glong num_chars;
- entry_text = gtk_entry_get_text (GTK_ENTRY (editable));
num_chars = g_utf8_strlen (new_text, text_length);
if (! entry->internal_operation)
@@ -1216,21 +1214,11 @@ static void
gimp_tag_entry_toggle_desc (GimpTagEntry *tag_entry,
gboolean show)
{
- GtkWidget *widget = GTK_WIDGET (tag_entry);
- const gchar *display_text;
+ GtkWidget *widget = GTK_WIDGET (tag_entry);
if (! (show ^ tag_entry->description_shown))
return;
- if (tag_entry->mode == GIMP_TAG_ENTRY_MODE_QUERY)
- {
- display_text = GIMP_TAG_ENTRY_QUERY_DESC;
- }
- else
- {
- display_text = GIMP_TAG_ENTRY_ASSIGN_DESC;
- }
-
if (show)
{
gchar *current_text;
diff --git a/app/widgets/gimptemplateview.c b/app/widgets/gimptemplateview.c
index 3c66c48..b88f96f 100644
--- a/app/widgets/gimptemplateview.c
+++ b/app/widgets/gimptemplateview.c
@@ -162,13 +162,11 @@ gimp_template_view_activate_item (GimpContainerEditor *editor,
{
GimpTemplateView *view = GIMP_TEMPLATE_VIEW (editor);
GimpContainer *container;
- GimpContext *context;
if (GIMP_CONTAINER_EDITOR_CLASS (parent_class)->activate_item)
GIMP_CONTAINER_EDITOR_CLASS (parent_class)->activate_item (editor, viewable);
container = gimp_container_view_get_container (editor->view);
- context = gimp_container_view_get_context (editor->view);
if (viewable && gimp_container_have (container, GIMP_OBJECT (viewable)))
{
diff --git a/app/widgets/gimptoolpresetfactoryview.c b/app/widgets/gimptoolpresetfactoryview.c
index 9f0a452..5ae85ba 100644
--- a/app/widgets/gimptoolpresetfactoryview.c
+++ b/app/widgets/gimptoolpresetfactoryview.c
@@ -59,7 +59,6 @@ gimp_tool_preset_factory_view_new (GimpViewType view_type,
GimpMenuFactory *menu_factory)
{
GimpToolPresetFactoryView *factory_view;
- GimpContainerEditor *editor;
g_return_val_if_fail (GIMP_IS_DATA_FACTORY (factory), NULL);
g_return_val_if_fail (view_size > 0 &&
@@ -83,8 +82,6 @@ gimp_tool_preset_factory_view_new (GimpViewType view_type,
return NULL;
}
- editor = GIMP_CONTAINER_EDITOR (factory_view);
-
gtk_widget_hide (gimp_data_factory_view_get_duplicate_button (GIMP_DATA_FACTORY_VIEW (factory_view)));
return GTK_WIDGET (factory_view);
diff --git a/app/widgets/gtkhwrapbox.c b/app/widgets/gtkhwrapbox.c
index 048387e..8c2bbe9 100644
--- a/app/widgets/gtkhwrapbox.c
+++ b/app/widgets/gtkhwrapbox.c
@@ -78,14 +78,10 @@ gtk_hwrap_box_get_type (void)
static void
gtk_hwrap_box_class_init (GtkHWrapBoxClass *class)
{
- GObjectClass *object_class;
GtkWidgetClass *widget_class;
- GtkContainerClass *container_class;
GtkWrapBoxClass *wrap_box_class;
- object_class = G_OBJECT_CLASS (class);
widget_class = GTK_WIDGET_CLASS (class);
- container_class = GTK_CONTAINER_CLASS (class);
wrap_box_class = GTK_WRAP_BOX_CLASS (class);
parent_class = g_type_class_peek_parent (class);
diff --git a/app/xcf/xcf-load.c b/app/xcf/xcf-load.c
index 63040c0..6319b37 100644
--- a/app/xcf/xcf-load.c
+++ b/app/xcf/xcf-load.c
@@ -1773,14 +1773,11 @@ xcf_load_vectors (XcfInfo *info,
guint32 active_index;
guint32 num_paths;
GimpVectors *active_vectors;
- guint32 base;
#ifdef GIMP_XCF_PATH_DEBUG
g_printerr ("xcf_load_vectors\n");
#endif
- base = info->cp;
-
info->cp += xcf_read_int32 (info->fp, &version, 1);
if (version != 1)
diff --git a/libgimp/gimpzoompreview.c b/libgimp/gimpzoompreview.c
index 971520e..99155b5 100644
--- a/libgimp/gimpzoompreview.c
+++ b/libgimp/gimpzoompreview.c
@@ -621,22 +621,19 @@ gimp_zoom_preview_set_drawable (GimpZoomPreview *preview,
GimpDrawable *drawable)
{
GimpZoomPreviewPrivate *priv = GIMP_ZOOM_PREVIEW_GET_PRIVATE (preview);
+ gint x, y;
gint width, height;
gint max_width, max_height;
- gint x1, y1;
- gint x2, y2;
g_return_if_fail (priv->drawable == NULL);
priv->drawable = drawable;
- if (gimp_drawable_mask_intersect (drawable->drawable_id, &x1, &y1, &width, &height))
+ if (gimp_drawable_mask_intersect (drawable->drawable_id,
+ &x, &y, &width, &height))
{
- x2 = x1 + width;
- y2 = y1 + height;
-
- priv->extents.x = x1;
- priv->extents.y = y1;
+ priv->extents.x = x;
+ priv->extents.y = y;
}
else
{
diff --git a/libgimpwidgets/gimpcolornotebook.c b/libgimpwidgets/gimpcolornotebook.c
index 620fc80..b3f3bf9 100644
--- a/libgimpwidgets/gimpcolornotebook.c
+++ b/libgimpwidgets/gimpcolornotebook.c
@@ -453,8 +453,7 @@ gimp_color_notebook_set_has_page (GimpColorNotebook *notebook,
GType page_type,
gboolean has_page)
{
- GimpColorSelector *selector;
- GList *list;
+ GList *list;
g_return_val_if_fail (GIMP_IS_COLOR_NOTEBOOK (notebook), NULL);
g_return_val_if_fail (g_type_is_a (page_type, GIMP_TYPE_COLOR_SELECTOR),
@@ -462,8 +461,6 @@ gimp_color_notebook_set_has_page (GimpColorNotebook *notebook,
g_return_val_if_fail (! g_type_is_a (page_type, GIMP_TYPE_COLOR_NOTEBOOK),
NULL);
- selector = GIMP_COLOR_SELECTOR (notebook);
-
for (list = notebook->selectors; list; list = g_list_next (list))
{
GimpColorSelector *page = list->data;
diff --git a/libgimpwidgets/gimppageselector.c b/libgimpwidgets/gimppageselector.c
index a285b54..6798ba2 100644
--- a/libgimpwidgets/gimppageselector.c
+++ b/libgimpwidgets/gimppageselector.c
@@ -1392,9 +1392,7 @@ stretch_frame_image (GdkPixbuf *frame_image,
gint dest_height)
{
GdkPixbuf *pixbuf;
- guchar *pixels;
gint frame_width, frame_height;
- gint row_stride;
gint target_width, target_frame_width;
gint target_height, target_frame_height;
@@ -1405,9 +1403,6 @@ stretch_frame_image (GdkPixbuf *frame_image,
dest_width, dest_height);
gdk_pixbuf_fill (pixbuf, 0);
- row_stride = gdk_pixbuf_get_rowstride (pixbuf);
- pixels = gdk_pixbuf_get_pixels (pixbuf);
-
target_width = dest_width - left_offset - right_offset;
target_height = dest_height - top_offset - bottom_offset;
target_frame_width = frame_width - left_offset - right_offset;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]