[gimp] Use display->gimp intead of display->image->gimp
- From: Michael Natterer <mitch src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gimp] Use display->gimp intead of display->image->gimp
- Date: Sun, 4 Oct 2009 18:05:53 +0000 (UTC)
commit 8ba18309eb3656a2d1976613b270f90e568f8edb
Author: Michael Natterer <mitch gimp org>
Date: Sun Oct 4 20:05:28 2009 +0200
Use display->gimp intead of display->image->gimp
app/actions/edit-commands.c | 6 +++---
app/actions/image-commands.c | 2 +-
app/actions/view-commands.c | 4 ++--
app/tools/gimpaligntool.c | 6 ++----
app/tools/gimpbucketfilltool.c | 2 +-
app/tools/gimpcolortool.c | 3 +--
app/tools/gimpeditselectiontool.c | 14 +++++++-------
app/tools/gimpmovetool.c | 10 ++++------
app/tools/gimppainttool.c | 2 +-
app/tools/gimptool.c | 4 ++--
app/tools/gimptransformtool.c | 4 ++--
11 files changed, 26 insertions(+), 31 deletions(-)
---
diff --git a/app/actions/edit-commands.c b/app/actions/edit-commands.c
index e02b9e6..ab1ecd8 100644
--- a/app/actions/edit-commands.c
+++ b/app/actions/edit-commands.c
@@ -492,7 +492,7 @@ edit_paste (GimpDisplay *display,
gchar *svg;
gsize svg_size;
- svg = gimp_clipboard_get_svg (display->image->gimp, &svg_size);
+ svg = gimp_clipboard_get_svg (display->gimp, &svg_size);
if (svg)
{
@@ -510,7 +510,7 @@ edit_paste (GimpDisplay *display,
{
GimpBuffer *buffer;
- buffer = gimp_clipboard_get_buffer (display->image->gimp);
+ buffer = gimp_clipboard_get_buffer (display->gimp);
if (buffer)
{
@@ -532,7 +532,7 @@ edit_paste (GimpDisplay *display,
}
else
{
- gimp_message_literal (display->image->gimp, G_OBJECT (display),
+ gimp_message_literal (display->gimp, G_OBJECT (display),
GIMP_MESSAGE_WARNING,
_("There is no image data in the clipboard to paste."));
}
diff --git a/app/actions/image-commands.c b/app/actions/image-commands.c
index 1eb8af7..996e26e 100644
--- a/app/actions/image-commands.c
+++ b/app/actions/image-commands.c
@@ -333,7 +333,7 @@ image_scale_cmd_callback (GtkAction *action,
image_scale_unit = gimp_display_get_shell (display)->unit;
if (image_scale_interp == -1)
- image_scale_interp = display->image->gimp->config->interpolation_type;
+ image_scale_interp = display->gimp->config->interpolation_type;
dialog = image_scale_dialog_new (display->image,
action_data_get_context (data),
diff --git a/app/actions/view-commands.c b/app/actions/view-commands.c
index 5858010..76b368b 100644
--- a/app/actions/view-commands.c
+++ b/app/actions/view-commands.c
@@ -65,7 +65,7 @@
#define IS_ACTIVE_DISPLAY(display) \
((display) == \
- gimp_context_get_display (gimp_get_user_context ((display)->image->gimp)))
+ gimp_context_get_display (gimp_get_user_context ((display)->gimp)))
/* local function prototypes */
@@ -88,7 +88,7 @@ view_new_cmd_callback (GtkAction *action,
shell = gimp_display_get_shell (display);
- gimp_create_display (display->image->gimp,
+ gimp_create_display (display->gimp,
display->image,
shell->unit, gimp_zoom_model_get_factor (shell->zoom));
}
diff --git a/app/tools/gimpaligntool.c b/app/tools/gimpaligntool.c
index 3fcb4c7..64408bf 100644
--- a/app/tools/gimpaligntool.c
+++ b/app/tools/gimpaligntool.c
@@ -353,8 +353,7 @@ gimp_align_tool_button_release (GimpTool *tool,
GimpLayer *layer;
gint snap_distance;
- snap_distance =
- GIMP_DISPLAY_CONFIG (display->image->gimp->config)->snap_distance;
+ snap_distance = GIMP_DISPLAY_CONFIG (display->gimp->config)->snap_distance;
if (gimp_draw_tool_on_vectors (GIMP_DRAW_TOOL (tool), display,
coords, snap_distance, snap_distance,
@@ -482,8 +481,7 @@ gimp_align_tool_oper_update (GimpTool *tool,
GimpDisplayShell *shell = gimp_display_get_shell (display);
gint snap_distance;
- snap_distance =
- GIMP_DISPLAY_CONFIG (display->image->gimp->config)->snap_distance;
+ snap_distance = GIMP_DISPLAY_CONFIG (display->gimp->config)->snap_distance;
if (gimp_draw_tool_on_vectors (GIMP_DRAW_TOOL (tool), display,
coords, snap_distance, snap_distance,
diff --git a/app/tools/gimpbucketfilltool.c b/app/tools/gimpbucketfilltool.c
index 5d175f9..fe956ec 100644
--- a/app/tools/gimpbucketfilltool.c
+++ b/app/tools/gimpbucketfilltool.c
@@ -190,7 +190,7 @@ gimp_bucket_fill_tool_button_release (GimpTool *tool,
options->sample_merged,
x, y, &error))
{
- gimp_message_literal (display->image->gimp, G_OBJECT (display),
+ gimp_message_literal (display->gimp, G_OBJECT (display),
GIMP_MESSAGE_WARNING, error->message);
g_clear_error (&error);
}
diff --git a/app/tools/gimpcolortool.c b/app/tools/gimpcolortool.c
index f0dd259..7bc5a8c 100644
--- a/app/tools/gimpcolortool.c
+++ b/app/tools/gimpcolortool.c
@@ -478,8 +478,7 @@ gimp_color_tool_oper_update (GimpTool *tool,
{
gint snap_distance;
- snap_distance =
- GIMP_DISPLAY_CONFIG (display->image->gimp->config)->snap_distance;
+ snap_distance = GIMP_DISPLAY_CONFIG (display->gimp->config)->snap_distance;
sample_point =
gimp_image_find_sample_point (display->image,
diff --git a/app/tools/gimpeditselectiontool.c b/app/tools/gimpeditselectiontool.c
index 734dd67..cfe5381 100644
--- a/app/tools/gimpeditselectiontool.c
+++ b/app/tools/gimpeditselectiontool.c
@@ -452,7 +452,7 @@ gimp_edit_selection_tool_start (GimpTool *parent_tool,
gimp_tool_control_activate (tool->control);
tool->display = display;
- tool_manager_push_tool (display->image->gimp, tool);
+ tool_manager_push_tool (display->gimp, tool);
/* pause the current selection */
gimp_display_shell_selection_control (shell, GIMP_SELECTION_PAUSE);
@@ -486,7 +486,7 @@ gimp_edit_selection_tool_button_release (GimpTool *tool,
/* Stop and free the selection core */
gimp_draw_tool_stop (GIMP_DRAW_TOOL (edit_select));
- tool_manager_pop_tool (display->image->gimp);
+ tool_manager_pop_tool (display->gimp);
active_item = gimp_edit_selection_tool_get_active_item (edit_select,
display->image);
@@ -576,9 +576,9 @@ gimp_edit_selection_tool_button_release (GimpTool *tool,
edit_select->num_segs_out = 0;
if (edit_select->propagate_release &&
- tool_manager_get_active (display->image->gimp))
+ tool_manager_get_active (display->gimp))
{
- tool_manager_button_release_active (display->image->gimp,
+ tool_manager_button_release_active (display->gimp,
coords, time, state,
display);
}
@@ -692,13 +692,13 @@ gimp_edit_selection_tool_update_motion (GimpEditSelectionTool *edit_select,
case GIMP_TRANSLATE_MODE_MASK_COPY_TO_LAYER:
if (! gimp_selection_float (GIMP_SELECTION (gimp_image_get_mask (display->image)),
GIMP_DRAWABLE (active_item),
- gimp_get_user_context (display->image->gimp),
+ gimp_get_user_context (display->gimp),
edit_select->edit_mode ==
GIMP_TRANSLATE_MODE_MASK_TO_LAYER,
0, 0, &error))
{
/* no region to float, abort safely */
- gimp_message_literal (display->image->gimp, G_OBJECT (display),
+ gimp_message_literal (display->gimp, G_OBJECT (display),
GIMP_MESSAGE_WARNING,
error->message);
g_clear_error (&error);
@@ -1318,7 +1318,7 @@ gimp_edit_selection_tool_translate (GimpTool *tool,
gimp_image_undo_group_end (display->image);
else
gimp_undo_refresh_preview (undo,
- gimp_get_user_context (display->image->gimp));
+ gimp_get_user_context (display->gimp));
gimp_image_flush (display->image);
diff --git a/app/tools/gimpmovetool.c b/app/tools/gimpmovetool.c
index 816ad05..c8b5181 100644
--- a/app/tools/gimpmovetool.c
+++ b/app/tools/gimpmovetool.c
@@ -250,7 +250,7 @@ gimp_move_tool_button_press (GimpTool *tool,
gint snap_distance;
snap_distance =
- GIMP_DISPLAY_CONFIG (display->image->gimp->config)->snap_distance;
+ GIMP_DISPLAY_CONFIG (display->gimp->config)->snap_distance;
if (gimp_display_shell_get_show_guides (shell) &&
(guide = gimp_image_find_guide (display->image,
@@ -360,7 +360,7 @@ gimp_move_tool_button_release (GimpTool *tool,
{
GimpMoveTool *move = GIMP_MOVE_TOOL (tool);
GimpDisplayShell *shell = gimp_display_get_shell (display);
- GimpGuiConfig *config = GIMP_GUI_CONFIG (display->image->gimp->config);
+ GimpGuiConfig *config = GIMP_GUI_CONFIG (display->gimp->config);
if (gimp_tool_control_is_active (tool->control))
gimp_tool_control_halt (tool->control);
@@ -665,8 +665,7 @@ gimp_move_tool_oper_update (GimpTool *tool,
{
gint snap_distance;
- snap_distance =
- GIMP_DISPLAY_CONFIG (display->image->gimp->config)->snap_distance;
+ snap_distance = GIMP_DISPLAY_CONFIG (display->gimp->config)->snap_distance;
guide = gimp_image_find_guide (display->image, coords->x, coords->y,
FUNSCALEX (shell, snap_distance),
@@ -737,8 +736,7 @@ gimp_move_tool_cursor_update (GimpTool *tool,
GimpLayer *layer;
gint snap_distance;
- snap_distance =
- GIMP_DISPLAY_CONFIG (display->image->gimp->config)->snap_distance;
+ snap_distance = GIMP_DISPLAY_CONFIG (display->gimp->config)->snap_distance;
if (gimp_display_shell_get_show_guides (shell) &&
(guide = gimp_image_find_guide (display->image, coords->x, coords->y,
diff --git a/app/tools/gimppainttool.c b/app/tools/gimppainttool.c
index 2cd5311..b89918e 100644
--- a/app/tools/gimppainttool.c
+++ b/app/tools/gimppainttool.c
@@ -478,7 +478,7 @@ gimp_paint_tool_modifier_key (GimpTool *tool,
{
if (press)
{
- GimpToolInfo *info = gimp_get_tool_info (display->image->gimp,
+ GimpToolInfo *info = gimp_get_tool_info (display->gimp,
"gimp-color-picker-tool");
if (GIMP_IS_TOOL_INFO (info))
diff --git a/app/tools/gimptool.c b/app/tools/gimptool.c
index 252d7df..3a4443f 100644
--- a/app/tools/gimptool.c
+++ b/app/tools/gimptool.c
@@ -1034,7 +1034,7 @@ gimp_tool_message (GimpTool *tool,
va_start (args, format);
- gimp_message_valist (display->image->gimp, G_OBJECT (display),
+ gimp_message_valist (display->gimp, G_OBJECT (display),
GIMP_MESSAGE_WARNING, format, args);
va_end (args);
@@ -1049,7 +1049,7 @@ gimp_tool_message_literal (GimpTool *tool,
g_return_if_fail (GIMP_IS_DISPLAY (display));
g_return_if_fail (message != NULL);
- gimp_message_literal (display->image->gimp, G_OBJECT (display),
+ gimp_message_literal (display->gimp, G_OBJECT (display),
GIMP_MESSAGE_WARNING, message);
}
diff --git a/app/tools/gimptransformtool.c b/app/tools/gimptransformtool.c
index 06d3d67..336be26 100644
--- a/app/tools/gimptransformtool.c
+++ b/app/tools/gimptransformtool.c
@@ -1223,7 +1223,7 @@ gimp_transform_tool_doit (GimpTransformTool *tr_tool,
mask_empty = gimp_channel_is_empty (gimp_image_get_mask (display->image));
- gimp_set_busy (display->image->gimp);
+ gimp_set_busy (display->gimp);
/* undraw the tool before we muck around with the transform matrix */
gimp_draw_tool_stop (GIMP_DRAW_TOOL (tr_tool));
@@ -1337,7 +1337,7 @@ gimp_transform_tool_doit (GimpTransformTool *tr_tool,
gtk_widget_queue_draw (shell->canvas);
}
- gimp_unset_busy (display->image->gimp);
+ gimp_unset_busy (display->gimp);
gimp_image_flush (display->image);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]