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

renamed gdisplays_reconnect() to gimp_displays_reconnect() and added a

2002-12-03  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplay-foreach.[ch]: renamed
	gdisplays_reconnect() to gimp_displays_reconnect() and added a
	"Gimp" parameter.

	* app/gui/file-commands.c
	* tools/pdbgen/pdb/display.pdb: changed accordingly.

	* tools/pdbgen/pdb/brush_select.pdb
	* tools/pdbgen/pdb/gradient_select.pdb
	* tools/pdbgen/pdb/palette_select.pdb
	* tools/pdbgen/pdb/pattern_select.pdb: some irrelevant
	code cleanups to make them look the same.

	* tools/pdbgen/pdb/message.pdb: changed $desc from "Interface"
	to "Message procedures".

	* tools/pdbgen/pdb/transform_tools.pdb: changed $desc from
	"Tool procedures" to "Transform Tool procedures".

	* app/pdb/brush_select_cmds.c
	* app/pdb/display_cmds.c
	* app/pdb/gradient_select_cmds.c
	* app/pdb/internal_procs.c
	* app/pdb/palette_select_cmds.c
	* app/pdb/pattern_select_cmds.c: regenerated.
parent 9eb748ad
2002-12-03 Michael Natterer <mitch@gimp.org>
* app/display/gimpdisplay-foreach.[ch]: renamed
gdisplays_reconnect() to gimp_displays_reconnect() and added a
"Gimp" parameter.
* app/gui/file-commands.c
* tools/pdbgen/pdb/display.pdb: changed accordingly.
* tools/pdbgen/pdb/brush_select.pdb
* tools/pdbgen/pdb/gradient_select.pdb
* tools/pdbgen/pdb/palette_select.pdb
* tools/pdbgen/pdb/pattern_select.pdb: some irrelevant
code cleanups to make them look the same.
* tools/pdbgen/pdb/message.pdb: changed $desc from "Interface"
to "Message procedures".
* tools/pdbgen/pdb/transform_tools.pdb: changed $desc from
"Tool procedures" to "Transform Tool procedures".
* app/pdb/brush_select_cmds.c
* app/pdb/display_cmds.c
* app/pdb/gradient_select_cmds.c
* app/pdb/internal_procs.c
* app/pdb/palette_select_cmds.c
* app/pdb/pattern_select_cmds.c: regenerated.
2002-12-03 Michael Natterer <mitch@gimp.org>
 
* libgimpwidgets/gimpcolorbutton.c: named the menu separator
......
......@@ -324,7 +324,7 @@ file_revert_confirm_callback (GtkWidget *widget,
{
undo_free (new_gimage);
gdisplays_reconnect (old_gimage, new_gimage);
gimp_displays_reconnect (old_gimage->gimp, old_gimage, new_gimage);
gimp_image_clean_all (new_gimage);
......
......@@ -149,16 +149,18 @@ gimp_displays_finish_draw (Gimp *gimp)
}
void
gdisplays_reconnect (GimpImage *old,
GimpImage *new)
gimp_displays_reconnect (Gimp *gimp,
GimpImage *old,
GimpImage *new)
{
GList *list;
GimpDisplay *gdisp;
g_return_if_fail (old != NULL);
g_return_if_fail (GIMP_IS_GIMP (gimp));
g_return_if_fail (GIMP_IS_IMAGE (old));
g_return_if_fail (GIMP_IS_IMAGE (new));
for (list = GIMP_LIST (new->gimp->displays)->list;
for (list = GIMP_LIST (gimp->displays)->list;
list;
list = g_list_next (list))
{
......
......@@ -22,13 +22,14 @@
GimpDisplay * gdisplays_check_valid (GimpDisplay *gdisp,
GimpImage *gimage);
void gdisplays_reconnect (GimpImage *old,
GimpImage *new);
gboolean gimp_displays_dirty (Gimp *gimp);
void gimp_displays_delete (Gimp *gimp);
void gimp_displays_flush (Gimp *gimp);
void gimp_displays_finish_draw (Gimp *gimp);
void gimp_displays_reconnect (Gimp *gimp,
GimpImage *old,
GimpImage *new);
void gimp_displays_set_busy (Gimp *gimp);
void gimp_displays_unset_busy (Gimp *gimp);
......
......@@ -324,7 +324,7 @@ file_revert_confirm_callback (GtkWidget *widget,
{
undo_free (new_gimage);
gdisplays_reconnect (old_gimage, new_gimage);
gimp_displays_reconnect (old_gimage->gimp, old_gimage, new_gimage);
gimp_image_clean_all (new_gimage);
......
......@@ -20,22 +20,20 @@
#include "config.h"
#include <string.h>
#include <gtk/gtk.h>
#include "libgimpbase/gimpbasetypes.h"
#include "pdb-types.h"
#include "widgets/widgets-types.h"
#include "gui/gui-types.h"
#include "procedural_db.h"
#include "base/base-enums.h"
#include "core/gimp.h"
#include "core/gimpbrush.h"
#include "core/gimpcontainer.h"
#include "core/gimpcontext.h"
#include "core/gimpdatafactory.h"
#include "core/gimplist.h"
#include "gui/brush-select.h"
#include "widgets/gimpbrushfactoryview.h"
......@@ -263,8 +261,6 @@ brushes_set_popup_invoker (Gimp *gimp,
spacing_adj = GIMP_BRUSH_FACTORY_VIEW (bsp->view)->spacing_adjustment;
/* Updating the context updates the widgets as well */
gimp_context_set_brush (bsp->context, active);
gimp_context_set_opacity (bsp->context, opacity / 100.0);
gimp_context_set_paint_mode (bsp->context, paint_mode);
......
......@@ -197,7 +197,7 @@ displays_reconnect_invoker (Gimp *gimp,
success = FALSE;
if (success)
gdisplays_reconnect(gimage_old, gimage_new);
gimp_displays_reconnect (gimp, gimage_old, gimage_new);
return procedural_db_return_args (&displays_reconnect_proc, success);
}
......
......@@ -20,7 +20,6 @@
#include "config.h"
#include <string.h>
#include <gtk/gtk.h>
......@@ -212,19 +211,14 @@ gradients_set_popup_invoker (Gimp *gimp,
(prec = procedural_db_lookup (gimp, gradient_callback)) &&
(gsp = gradient_select_get_by_callback (gradient_callback)))
{
GimpGradient *active = NULL;
active = (GimpGradient *)
GimpGradient *active = (GimpGradient *)
gimp_container_get_child_by_name (gimp->gradient_factory->container,
gradient_name);
if (active)
{
gimp_context_set_gradient (gsp->context, active);
success = TRUE;
}
else
success = FALSE;
success = (active != NULL);
if (success)
gimp_context_set_gradient (gsp->context, active);
}
else
success = FALSE;
......
......@@ -91,7 +91,7 @@ internal_procs_init (Gimp *gimp,
(* status_callback) (NULL, _("Convert"), 0.124);
register_convert_procs (gimp);
(* status_callback) (NULL, _("GimpDisplay procedures"), 0.133);
(* status_callback) (NULL, _("Display procedures"), 0.133);
register_display_procs (gimp);
(* status_callback) (NULL, _("Drawable procedures"), 0.145);
......@@ -127,7 +127,7 @@ internal_procs_init (Gimp *gimp,
(* status_callback) (NULL, _("Layer"), 0.518);
register_layer_procs (gimp);
(* status_callback) (NULL, _("Interface"), 0.612);
(* status_callback) (NULL, _("Message procedures"), 0.612);
register_message_procs (gimp);
(* status_callback) (NULL, _("Miscellaneous"), 0.621);
......@@ -175,7 +175,7 @@ internal_procs_init (Gimp *gimp,
(* status_callback) (NULL, _("Text procedures"), 0.929);
register_text_tool_procs (gimp);
(* status_callback) (NULL, _("Tool procedures"), 0.941);
(* status_callback) (NULL, _("Transform Tool procedures"), 0.941);
register_transform_tools_procs (gimp);
(* status_callback) (NULL, _("Undo"), 0.959);
......
......@@ -20,7 +20,6 @@
#include "config.h"
#include <string.h>
#include <gtk/gtk.h>
......
......@@ -20,7 +20,6 @@
#include "config.h"
#include <string.h>
#include <gtk/gtk.h>
......
......@@ -123,9 +123,7 @@ sub brushes_set_popup {
);
%invoke = (
headers => [ qw("core/gimpbrush.h" "core/gimplist.h"
"widgets/widgets-types.h"
"widgets/gimpbrushfactoryview.h") ],
headers => [ qw("widgets/gimpbrushfactoryview.h") ],
vars => [ 'ProcRecord *proc', 'BrushSelect *bsp' ],
code => <<'CODE'
{
......@@ -145,8 +143,6 @@ sub brushes_set_popup {
spacing_adj = GIMP_BRUSH_FACTORY_VIEW (bsp->view)->spacing_adjustment;
/* Updating the context updates the widgets as well */
gimp_context_set_brush (bsp->context, active);
gimp_context_set_opacity (bsp->context, opacity / 100.0);
gimp_context_set_paint_mode (bsp->context, paint_mode);
......@@ -161,8 +157,9 @@ CODE
);
}
@headers = qw(<string.h> "core/gimp.h" "core/gimpcontext.h"
"core/gimpdatafactory.h" "gui/brush-select.h");
@headers = qw("core/gimp.h" "core/gimpcontext.h"
"core/gimpcontainer.h" "core/gimpdatafactory.h"
"gui/gui-types.h" "gui/brush-select.h");
@procs = qw(brushes_popup brushes_close_popup brushes_set_popup);
%exports = (app => [@procs], lib => [@procs]);
......
......@@ -108,7 +108,7 @@ HELP
alias => 'gimage_new' }
);
%invoke = ( code => 'gdisplays_reconnect(gimage_old, gimage_new);' );
%invoke = ( code => 'gimp_displays_reconnect (gimp, gimage_old, gimage_new);' );
}
@headers = qw("core/gimp.h" "display/display-types.h" "display/gimpdisplay.h"
......@@ -117,6 +117,6 @@ HELP
@procs = qw(display_new display_delete displays_flush displays_reconnect);
%exports = (app => [@procs], lib => [@procs]);
$desc = 'GimpDisplay procedures';
$desc = 'Display procedures';
1;
......@@ -124,19 +124,14 @@ sub gradients_set_popup {
(prec = procedural_db_lookup (gimp, gradient_callback)) &&
(gsp = gradient_select_get_by_callback (gradient_callback)))
{
GimpGradient *active = NULL;
active = (GimpGradient *)
GimpGradient *active = (GimpGradient *)
gimp_container_get_child_by_name (gimp->gradient_factory->container,
gradient_name);
if (active)
{
gimp_context_set_gradient (gsp->context, active);
success = TRUE;
}
else
success = FALSE;
success = (active != NULL);
if (success)
gimp_context_set_gradient (gsp->context, active);
}
else
success = FALSE;
......@@ -145,7 +140,7 @@ CODE
);
}
@headers = qw(<string.h> "core/gimp.h" "core/gimpcontext.h"
@headers = qw("core/gimp.h" "core/gimpcontext.h"
"core/gimpcontainer.h" "core/gimpdatafactory.h"
"core/gimpgradient.h"
"gui/gui-types.h" "gui/gradient-select.h");
......
......@@ -81,6 +81,6 @@ HELP
@procs = qw(message message_get_handler message_set_handler);
%exports = (app => [@procs], lib => [@procs]);
$desc = 'Interface';
$desc = 'Message procedures';
1;
......@@ -130,8 +130,8 @@ CODE
);
}
@headers = qw(<string.h> "core/gimp.h" "core/gimpcontext.h"
"core/gimpdatafactory.h" "core/gimpcontainer.h"
@headers = qw("core/gimp.h" "core/gimpcontext.h"
"core/gimpcontainer.h" "core/gimpdatafactory.h"
"gui/gui-types.h" "gui/palette-select.h");
@procs = qw(palettes_popup palettes_close_popup palettes_set_popup);
......
......@@ -129,8 +129,8 @@ CODE
);
}
@headers = qw(<string.h> "core/gimp.h" "core/gimpcontext.h"
"core/gimpdatafactory.h" "core/gimpcontainer.h"
@headers = qw("core/gimp.h" "core/gimpcontext.h"
"core/gimpcontainer.h" "core/gimpdatafactory.h"
"gui/gui-types.h" "gui/pattern-select.h");
@procs = qw(patterns_popup patterns_close_popup patterns_set_popup);
......
......@@ -436,6 +436,6 @@ CODE
%exports = (app => [@procs], lib => [@procs]);
$desc = 'Tool procedures';
$desc = 'Transform Tool procedures';
1;
Markdown is supported
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