2001-02-05 15:22:20 +00:00
|
|
|
/* The GIMP -- an image manipulation program
|
|
|
|
* Copyright (C) 1995 Spencer Kimball and Peter Mattis
|
|
|
|
*
|
2001-04-22 00:38:56 +00:00
|
|
|
* gimpcontainerview.c
|
2003-12-21 16:11:06 +00:00
|
|
|
* Copyright (C) 2001-2003 Michael Natterer <mitch@gimp.org>
|
2001-04-22 00:38:56 +00:00
|
|
|
*
|
2001-02-05 15:22:20 +00:00
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include "config.h"
|
|
|
|
|
2003-10-10 21:24:12 +00:00
|
|
|
#include <string.h>
|
|
|
|
|
2001-02-05 15:22:20 +00:00
|
|
|
#include <gtk/gtk.h>
|
|
|
|
|
2001-08-04 20:38:54 +00:00
|
|
|
#include "libgimpwidgets/gimpwidgets.h"
|
|
|
|
|
2001-05-08 03:48:54 +00:00
|
|
|
#include "widgets-types.h"
|
2001-02-05 15:22:20 +00:00
|
|
|
|
2001-05-09 02:32:03 +00:00
|
|
|
#include "core/gimpcontainer.h"
|
|
|
|
#include "core/gimpcontext.h"
|
|
|
|
#include "core/gimpmarshal.h"
|
|
|
|
#include "core/gimpviewable.h"
|
|
|
|
|
2001-02-05 15:22:20 +00:00
|
|
|
#include "gimpcontainerview.h"
|
2001-02-18 19:44:28 +00:00
|
|
|
#include "gimpdnd.h"
|
2003-04-08 12:39:02 +00:00
|
|
|
#include "gimppreviewrenderer.h"
|
2001-05-08 03:48:54 +00:00
|
|
|
|
2001-02-05 19:10:40 +00:00
|
|
|
|
2003-12-21 16:11:06 +00:00
|
|
|
enum
|
|
|
|
{
|
|
|
|
PROP_0,
|
|
|
|
PROP_CONTAINER,
|
|
|
|
PROP_CONTEXT
|
|
|
|
};
|
|
|
|
|
2001-02-05 19:10:40 +00:00
|
|
|
enum
|
|
|
|
{
|
2001-02-07 15:01:52 +00:00
|
|
|
SELECT_ITEM,
|
2001-02-18 19:44:28 +00:00
|
|
|
ACTIVATE_ITEM,
|
2001-04-29 15:23:01 +00:00
|
|
|
CONTEXT_ITEM,
|
2001-02-05 19:10:40 +00:00
|
|
|
LAST_SIGNAL
|
|
|
|
};
|
|
|
|
|
|
|
|
|
2003-10-10 21:24:12 +00:00
|
|
|
static void gimp_container_view_class_init (GimpContainerViewClass *klass);
|
|
|
|
static void gimp_container_view_init (GimpContainerView *view,
|
|
|
|
GimpContainerViewClass *klass);
|
2001-08-03 19:43:19 +00:00
|
|
|
|
2003-12-21 16:11:06 +00:00
|
|
|
static void gimp_container_view_set_property (GObject *object,
|
|
|
|
guint property_id,
|
|
|
|
const GValue *value,
|
|
|
|
GParamSpec *pspec);
|
|
|
|
static void gimp_container_view_get_property (GObject *object,
|
|
|
|
guint property_id,
|
|
|
|
GValue *value,
|
|
|
|
GParamSpec *pspec);
|
|
|
|
|
|
|
|
static void gimp_container_view_destroy (GtkObject *object);
|
2001-02-05 19:10:40 +00:00
|
|
|
|
2001-03-11 17:24:47 +00:00
|
|
|
static void gimp_container_view_real_set_container (GimpContainerView *view,
|
|
|
|
GimpContainer *container);
|
|
|
|
|
2001-02-08 04:16:41 +00:00
|
|
|
static void gimp_container_view_clear_items (GimpContainerView *view);
|
|
|
|
static void gimp_container_view_real_clear_items (GimpContainerView *view);
|
2001-02-05 15:22:20 +00:00
|
|
|
|
2001-02-05 19:10:40 +00:00
|
|
|
static void gimp_container_view_add_foreach (GimpViewable *viewable,
|
|
|
|
GimpContainerView *view);
|
|
|
|
static void gimp_container_view_add (GimpContainerView *view,
|
|
|
|
GimpViewable *viewable,
|
|
|
|
GimpContainer *container);
|
|
|
|
static void gimp_container_view_remove (GimpContainerView *view,
|
|
|
|
GimpViewable *viewable,
|
|
|
|
GimpContainer *container);
|
2001-02-17 21:20:10 +00:00
|
|
|
static void gimp_container_view_reorder (GimpContainerView *view,
|
|
|
|
GimpViewable *viewable,
|
|
|
|
gint new_index,
|
|
|
|
GimpContainer *container);
|
2001-02-05 15:22:20 +00:00
|
|
|
|
2003-10-18 16:23:15 +00:00
|
|
|
static void gimp_container_view_freeze (GimpContainerView *view,
|
|
|
|
GimpContainer *container);
|
|
|
|
static void gimp_container_view_thaw (GimpContainerView *view,
|
|
|
|
GimpContainer *container);
|
2004-01-29 16:34:41 +00:00
|
|
|
static void gimp_container_view_name_changed (GimpViewable *viewable,
|
|
|
|
GimpContainerView *view);
|
2003-10-18 16:23:15 +00:00
|
|
|
|
2001-08-04 20:38:54 +00:00
|
|
|
static void gimp_container_view_context_changed (GimpContext *context,
|
|
|
|
GimpViewable *viewable,
|
|
|
|
GimpContainerView *view);
|
|
|
|
static void gimp_container_view_viewable_dropped (GtkWidget *widget,
|
|
|
|
GimpViewable *viewable,
|
|
|
|
gpointer data);
|
|
|
|
static void gimp_container_view_button_viewable_dropped (GtkWidget *widget,
|
2001-02-18 19:44:28 +00:00
|
|
|
GimpViewable *viewable,
|
|
|
|
gpointer data);
|
2001-02-07 15:01:52 +00:00
|
|
|
|
2001-02-05 15:22:20 +00:00
|
|
|
|
2001-02-05 19:10:40 +00:00
|
|
|
static guint view_signals[LAST_SIGNAL] = { 0 };
|
2001-02-05 15:22:20 +00:00
|
|
|
|
2002-03-08 00:27:45 +00:00
|
|
|
static GimpEditorClass *parent_class = NULL;
|
2001-02-05 15:22:20 +00:00
|
|
|
|
|
|
|
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
GType
|
2001-02-05 15:22:20 +00:00
|
|
|
gimp_container_view_get_type (void)
|
|
|
|
{
|
2003-10-10 21:24:12 +00:00
|
|
|
static GType type = 0;
|
2001-02-05 15:22:20 +00:00
|
|
|
|
2003-10-10 21:24:12 +00:00
|
|
|
if (! type)
|
2001-02-05 15:22:20 +00:00
|
|
|
{
|
2001-10-17 11:33:43 +00:00
|
|
|
static const GTypeInfo view_info =
|
2001-02-05 15:22:20 +00:00
|
|
|
{
|
2001-10-17 11:33:43 +00:00
|
|
|
sizeof (GimpContainerViewClass),
|
|
|
|
NULL, /* base_init */
|
|
|
|
NULL, /* base_finalize */
|
|
|
|
(GClassInitFunc) gimp_container_view_class_init,
|
|
|
|
NULL, /* class_finalize */
|
|
|
|
NULL, /* class_data */
|
|
|
|
sizeof (GimpContainerView),
|
|
|
|
0, /* n_preallocs */
|
|
|
|
(GInstanceInitFunc) gimp_container_view_init,
|
2001-02-05 15:22:20 +00:00
|
|
|
};
|
2003-10-10 21:24:12 +00:00
|
|
|
|
|
|
|
type = g_type_register_static (GIMP_TYPE_EDITOR,
|
|
|
|
"GimpContainerView",
|
|
|
|
&view_info, 0);
|
2001-02-05 15:22:20 +00:00
|
|
|
}
|
|
|
|
|
2003-10-10 21:24:12 +00:00
|
|
|
return type;
|
2001-02-05 15:22:20 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
gimp_container_view_class_init (GimpContainerViewClass *klass)
|
|
|
|
{
|
2004-05-10 11:08:51 +00:00
|
|
|
GObjectClass *object_class = G_OBJECT_CLASS (klass);
|
|
|
|
GtkObjectClass *gtk_object_class = GTK_OBJECT_CLASS (klass);
|
2001-10-17 11:33:43 +00:00
|
|
|
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
parent_class = g_type_class_peek_parent (klass);
|
2001-02-05 15:22:20 +00:00
|
|
|
|
2001-02-07 15:01:52 +00:00
|
|
|
view_signals[SELECT_ITEM] =
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
g_signal_new ("select_item",
|
|
|
|
G_TYPE_FROM_CLASS (klass),
|
2003-05-18 13:28:27 +00:00
|
|
|
G_SIGNAL_RUN_LAST,
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
G_STRUCT_OFFSET (GimpContainerViewClass, select_item),
|
|
|
|
NULL, NULL,
|
2003-05-18 13:28:27 +00:00
|
|
|
gimp_marshal_BOOLEAN__OBJECT_POINTER,
|
|
|
|
G_TYPE_BOOLEAN, 2,
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
GIMP_TYPE_OBJECT,
|
|
|
|
G_TYPE_POINTER);
|
2001-02-07 15:01:52 +00:00
|
|
|
|
2001-02-18 19:44:28 +00:00
|
|
|
view_signals[ACTIVATE_ITEM] =
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
g_signal_new ("activate_item",
|
|
|
|
G_TYPE_FROM_CLASS (klass),
|
|
|
|
G_SIGNAL_RUN_FIRST,
|
|
|
|
G_STRUCT_OFFSET (GimpContainerViewClass, activate_item),
|
|
|
|
NULL, NULL,
|
2001-11-22 23:46:13 +00:00
|
|
|
gimp_marshal_VOID__OBJECT_POINTER,
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
G_TYPE_NONE, 2,
|
|
|
|
GIMP_TYPE_OBJECT,
|
|
|
|
G_TYPE_POINTER);
|
2001-02-18 19:44:28 +00:00
|
|
|
|
2001-04-29 15:23:01 +00:00
|
|
|
view_signals[CONTEXT_ITEM] =
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
g_signal_new ("context_item",
|
|
|
|
G_TYPE_FROM_CLASS (klass),
|
|
|
|
G_SIGNAL_RUN_FIRST,
|
|
|
|
G_STRUCT_OFFSET (GimpContainerViewClass, context_item),
|
|
|
|
NULL, NULL,
|
2001-11-22 23:46:13 +00:00
|
|
|
gimp_marshal_VOID__OBJECT_POINTER,
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
G_TYPE_NONE, 2,
|
|
|
|
GIMP_TYPE_OBJECT,
|
|
|
|
G_TYPE_POINTER);
|
2001-04-29 15:23:01 +00:00
|
|
|
|
2003-12-21 16:11:06 +00:00
|
|
|
object_class->set_property = gimp_container_view_set_property;
|
|
|
|
object_class->get_property = gimp_container_view_get_property;
|
|
|
|
|
|
|
|
gtk_object_class->destroy = gimp_container_view_destroy;
|
2001-02-07 15:01:52 +00:00
|
|
|
|
2003-12-21 16:11:06 +00:00
|
|
|
klass->select_item = NULL;
|
|
|
|
klass->activate_item = NULL;
|
|
|
|
klass->context_item = NULL;
|
2001-08-07 12:42:23 +00:00
|
|
|
|
2003-12-21 16:11:06 +00:00
|
|
|
klass->set_container = gimp_container_view_real_set_container;
|
|
|
|
klass->insert_item = NULL;
|
|
|
|
klass->remove_item = NULL;
|
|
|
|
klass->reorder_item = NULL;
|
2004-01-29 16:34:41 +00:00
|
|
|
klass->rename_item = NULL;
|
2003-12-21 16:11:06 +00:00
|
|
|
klass->clear_items = gimp_container_view_real_clear_items;
|
|
|
|
klass->set_preview_size = NULL;
|
2003-02-24 20:31:14 +00:00
|
|
|
|
|
|
|
klass->insert_data_free = NULL;
|
2003-12-21 16:11:06 +00:00
|
|
|
|
|
|
|
g_object_class_install_property (object_class, PROP_CONTAINER,
|
|
|
|
g_param_spec_object ("container", NULL, NULL,
|
|
|
|
GIMP_TYPE_CONTAINER,
|
|
|
|
G_PARAM_READWRITE));
|
|
|
|
g_object_class_install_property (object_class, PROP_CONTEXT,
|
|
|
|
g_param_spec_object ("context", NULL, NULL,
|
|
|
|
GIMP_TYPE_CONTEXT,
|
|
|
|
G_PARAM_READWRITE));
|
|
|
|
|
2001-02-05 15:22:20 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
2003-02-24 20:31:14 +00:00
|
|
|
gimp_container_view_init (GimpContainerView *view,
|
|
|
|
GimpContainerViewClass *klass)
|
2001-02-05 15:22:20 +00:00
|
|
|
{
|
2003-04-04 21:16:58 +00:00
|
|
|
view->container = NULL;
|
|
|
|
view->context = NULL;
|
|
|
|
view->hash_table = g_hash_table_new_full (g_direct_hash,
|
|
|
|
g_direct_equal,
|
|
|
|
NULL,
|
|
|
|
klass->insert_data_free);
|
|
|
|
view->preview_size = 0;
|
|
|
|
view->preview_border_width = 1;
|
|
|
|
view->reorderable = FALSE;
|
2001-02-05 15:22:20 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
2003-12-21 16:11:06 +00:00
|
|
|
gimp_container_view_set_property (GObject *object,
|
|
|
|
guint property_id,
|
|
|
|
const GValue *value,
|
|
|
|
GParamSpec *pspec)
|
2001-02-05 15:22:20 +00:00
|
|
|
{
|
2003-12-21 16:11:06 +00:00
|
|
|
GimpContainerView *view = GIMP_CONTAINER_VIEW (object);
|
2001-02-05 15:22:20 +00:00
|
|
|
|
2003-12-21 16:11:06 +00:00
|
|
|
switch (property_id)
|
|
|
|
{
|
|
|
|
case PROP_CONTAINER:
|
|
|
|
gimp_container_view_set_container (view, g_value_get_object (value));
|
|
|
|
break;
|
|
|
|
case PROP_CONTEXT:
|
|
|
|
gimp_container_view_set_context (view, g_value_get_object (value));
|
|
|
|
break;
|
|
|
|
default:
|
|
|
|
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
gimp_container_view_get_property (GObject *object,
|
|
|
|
guint property_id,
|
|
|
|
GValue *value,
|
|
|
|
GParamSpec *pspec)
|
|
|
|
{
|
|
|
|
GimpContainerView *view = GIMP_CONTAINER_VIEW (object);
|
|
|
|
|
|
|
|
switch (property_id)
|
|
|
|
{
|
|
|
|
case PROP_CONTAINER:
|
|
|
|
g_value_set_object (value, view->container);
|
|
|
|
break;
|
|
|
|
case PROP_CONTEXT:
|
|
|
|
g_value_set_object (value, view->context);
|
|
|
|
break;
|
|
|
|
default:
|
|
|
|
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
gimp_container_view_destroy (GtkObject *object)
|
|
|
|
{
|
|
|
|
GimpContainerView *view = GIMP_CONTAINER_VIEW (object);
|
2001-02-05 19:10:40 +00:00
|
|
|
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
if (view->container)
|
|
|
|
gimp_container_view_set_container (view, NULL);
|
2001-02-08 04:16:41 +00:00
|
|
|
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
if (view->context)
|
|
|
|
gimp_container_view_set_context (view, NULL);
|
2001-02-08 04:16:41 +00:00
|
|
|
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
if (view->hash_table)
|
|
|
|
{
|
|
|
|
g_hash_table_destroy (view->hash_table);
|
|
|
|
view->hash_table = NULL;
|
|
|
|
}
|
2001-02-08 04:16:41 +00:00
|
|
|
|
2003-03-16 11:14:29 +00:00
|
|
|
GTK_OBJECT_CLASS (parent_class)->destroy (object);
|
2001-02-05 15:22:20 +00:00
|
|
|
}
|
2001-02-05 19:10:40 +00:00
|
|
|
|
|
|
|
void
|
|
|
|
gimp_container_view_set_container (GimpContainerView *view,
|
|
|
|
GimpContainer *container)
|
|
|
|
{
|
|
|
|
g_return_if_fail (GIMP_IS_CONTAINER_VIEW (view));
|
2003-04-04 21:16:58 +00:00
|
|
|
g_return_if_fail (container == NULL || GIMP_IS_CONTAINER (container));
|
2001-02-05 19:10:40 +00:00
|
|
|
|
2001-08-07 12:42:23 +00:00
|
|
|
if (container != view->container)
|
2003-12-21 16:11:06 +00:00
|
|
|
{
|
|
|
|
GIMP_CONTAINER_VIEW_GET_CLASS (view)->set_container (view, container);
|
|
|
|
|
|
|
|
g_object_notify (G_OBJECT (view), "container");
|
|
|
|
}
|
2001-03-11 17:24:47 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
gimp_container_view_real_set_container (GimpContainerView *view,
|
|
|
|
GimpContainer *container)
|
|
|
|
{
|
2001-02-05 19:10:40 +00:00
|
|
|
if (view->container)
|
|
|
|
{
|
2003-02-24 20:31:14 +00:00
|
|
|
GimpContainerViewClass *view_class;
|
|
|
|
|
2001-03-06 13:28:39 +00:00
|
|
|
gimp_container_view_select_item (view, NULL);
|
2001-02-08 04:16:41 +00:00
|
|
|
gimp_container_view_clear_items (view);
|
|
|
|
|
2004-01-29 16:34:41 +00:00
|
|
|
gimp_container_remove_handler (view->container,
|
|
|
|
view->name_changed_handler_id);
|
|
|
|
|
2003-01-05 22:07:10 +00:00
|
|
|
g_signal_handlers_disconnect_by_func (view->container,
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
gimp_container_view_add,
|
|
|
|
view);
|
2003-01-05 22:07:10 +00:00
|
|
|
g_signal_handlers_disconnect_by_func (view->container,
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
gimp_container_view_remove,
|
|
|
|
view);
|
2003-01-05 22:07:10 +00:00
|
|
|
g_signal_handlers_disconnect_by_func (view->container,
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
gimp_container_view_reorder,
|
|
|
|
view);
|
2003-10-18 16:23:15 +00:00
|
|
|
g_signal_handlers_disconnect_by_func (view->container,
|
|
|
|
gimp_container_view_freeze,
|
|
|
|
view);
|
|
|
|
g_signal_handlers_disconnect_by_func (view->container,
|
|
|
|
gimp_container_view_thaw,
|
|
|
|
view);
|
2001-02-05 19:10:40 +00:00
|
|
|
|
2003-02-26 16:17:10 +00:00
|
|
|
g_hash_table_destroy (view->hash_table);
|
2003-02-24 20:31:14 +00:00
|
|
|
|
|
|
|
view_class = GIMP_CONTAINER_VIEW_GET_CLASS (view);
|
2001-02-05 19:10:40 +00:00
|
|
|
|
2003-02-24 20:31:14 +00:00
|
|
|
view->hash_table = g_hash_table_new_full (g_direct_hash, g_direct_equal,
|
|
|
|
NULL,
|
|
|
|
view_class->insert_data_free);
|
2001-02-07 15:01:52 +00:00
|
|
|
|
|
|
|
if (view->context)
|
|
|
|
{
|
2003-01-05 22:07:10 +00:00
|
|
|
g_signal_handlers_disconnect_by_func (view->context,
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
gimp_container_view_context_changed,
|
|
|
|
view);
|
2001-02-18 19:44:28 +00:00
|
|
|
|
2001-08-04 20:38:54 +00:00
|
|
|
if (view->dnd_widget)
|
|
|
|
{
|
|
|
|
gtk_drag_dest_unset (GTK_WIDGET (view->dnd_widget));
|
2002-09-02 14:39:08 +00:00
|
|
|
gimp_dnd_viewable_dest_remove (GTK_WIDGET (view->dnd_widget),
|
|
|
|
view->container->children_type);
|
2001-08-04 20:38:54 +00:00
|
|
|
}
|
2001-02-07 15:01:52 +00:00
|
|
|
}
|
2001-02-05 19:10:40 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
view->container = container;
|
|
|
|
|
|
|
|
if (view->container)
|
|
|
|
{
|
2004-01-29 16:34:41 +00:00
|
|
|
GimpViewableClass *viewable_class;
|
|
|
|
|
|
|
|
viewable_class = g_type_class_ref (container->children_type);
|
|
|
|
|
2001-02-08 04:16:41 +00:00
|
|
|
gimp_container_foreach (view->container,
|
2001-02-05 19:10:40 +00:00
|
|
|
(GFunc) gimp_container_view_add_foreach,
|
|
|
|
view);
|
|
|
|
|
2004-01-29 16:34:41 +00:00
|
|
|
view->name_changed_handler_id =
|
|
|
|
gimp_container_add_handler (view->container,
|
|
|
|
viewable_class->name_changed_signal,
|
|
|
|
G_CALLBACK (gimp_container_view_name_changed),
|
|
|
|
view);
|
|
|
|
|
|
|
|
g_type_class_unref (viewable_class);
|
|
|
|
|
2003-01-05 22:07:10 +00:00
|
|
|
g_signal_connect_object (view->container, "add",
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
G_CALLBACK (gimp_container_view_add),
|
2003-01-05 22:07:10 +00:00
|
|
|
view,
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
G_CONNECT_SWAPPED);
|
2003-01-05 22:07:10 +00:00
|
|
|
g_signal_connect_object (view->container, "remove",
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
G_CALLBACK (gimp_container_view_remove),
|
2003-01-05 22:07:10 +00:00
|
|
|
view,
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
G_CONNECT_SWAPPED);
|
2003-01-05 22:07:10 +00:00
|
|
|
g_signal_connect_object (view->container, "reorder",
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
G_CALLBACK (gimp_container_view_reorder),
|
2003-01-05 22:07:10 +00:00
|
|
|
view,
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
G_CONNECT_SWAPPED);
|
2003-10-18 16:23:15 +00:00
|
|
|
g_signal_connect_object (view->container, "freeze",
|
|
|
|
G_CALLBACK (gimp_container_view_freeze),
|
|
|
|
view,
|
|
|
|
G_CONNECT_SWAPPED);
|
|
|
|
g_signal_connect_object (view->container, "thaw",
|
|
|
|
G_CALLBACK (gimp_container_view_thaw),
|
|
|
|
view,
|
|
|
|
G_CONNECT_SWAPPED);
|
2001-02-17 21:20:10 +00:00
|
|
|
|
2001-02-07 15:01:52 +00:00
|
|
|
if (view->context)
|
|
|
|
{
|
2001-02-08 04:16:41 +00:00
|
|
|
GimpObject *object;
|
|
|
|
const gchar *signal_name;
|
|
|
|
|
|
|
|
signal_name =
|
|
|
|
gimp_context_type_to_signal_name (view->container->children_type);
|
|
|
|
|
2003-01-05 22:07:10 +00:00
|
|
|
g_signal_connect_object (view->context, signal_name,
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
G_CALLBACK (gimp_container_view_context_changed),
|
2003-01-05 22:07:10 +00:00
|
|
|
view,
|
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-07-24 21:27:11 +00:00
|
|
|
0);
|
2001-02-07 15:01:52 +00:00
|
|
|
|
2001-02-08 04:16:41 +00:00
|
|
|
object = gimp_context_get_by_type (view->context,
|
|
|
|
view->container->children_type);
|
|
|
|
|
2003-03-16 11:14:29 +00:00
|
|
|
gimp_container_view_select_item (view, (GimpViewable *) object);
|
2001-02-18 19:44:28 +00:00
|
|
|
|
2001-08-04 20:38:54 +00:00
|
|
|
if (view->dnd_widget)
|
2002-09-02 14:39:08 +00:00
|
|
|
gimp_dnd_viewable_dest_add (GTK_WIDGET (view->dnd_widget),
|
|
|
|
view->container->children_type,
|
|
|
|
gimp_container_view_viewable_dropped,
|
|
|
|
view);
|
2001-02-07 15:01:52 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2003-03-26 17:49:42 +00:00
|
|
|
void
|
|
|
|
gimp_container_view_construct (GimpContainerView *view,
|
|
|
|
GimpContainer *container,
|
|
|
|
GimpContext *context,
|
|
|
|
gint preview_size,
|
2003-04-08 12:39:02 +00:00
|
|
|
gint preview_border_width,
|
|
|
|
gboolean reorderable)
|
2003-03-26 17:49:42 +00:00
|
|
|
{
|
|
|
|
g_return_if_fail (GIMP_IS_CONTAINER_VIEW (view));
|
|
|
|
g_return_if_fail (container == NULL || GIMP_IS_CONTAINER (container));
|
|
|
|
g_return_if_fail (context == NULL || GIMP_IS_CONTEXT (context));
|
2003-04-01 13:53:47 +00:00
|
|
|
g_return_if_fail (preview_size > 0 &&
|
|
|
|
preview_size <= GIMP_VIEWABLE_MAX_PREVIEW_SIZE);
|
2003-04-08 12:39:02 +00:00
|
|
|
g_return_if_fail (preview_border_width >= 0 &&
|
|
|
|
preview_border_width <= GIMP_PREVIEW_MAX_BORDER_WIDTH);
|
2003-03-26 17:49:42 +00:00
|
|
|
|
|
|
|
view->reorderable = reorderable ? TRUE : FALSE;
|
|
|
|
|
2003-04-08 12:39:02 +00:00
|
|
|
gimp_container_view_set_preview_size (view, preview_size,
|
|
|
|
preview_border_width);
|
2003-03-26 17:49:42 +00:00
|
|
|
|
|
|
|
if (container)
|
|
|
|
gimp_container_view_set_container (view, container);
|
|
|
|
|
|
|
|
if (context)
|
|
|
|
gimp_container_view_set_context (view, context);
|
|
|
|
}
|
|
|
|
|
2001-02-07 15:01:52 +00:00
|
|
|
void
|
|
|
|
gimp_container_view_set_context (GimpContainerView *view,
|
|
|
|
GimpContext *context)
|
|
|
|
{
|
|
|
|
g_return_if_fail (GIMP_IS_CONTAINER_VIEW (view));
|
|
|
|
g_return_if_fail (! context || GIMP_IS_CONTEXT (context));
|
|
|
|
|
|
|
|
if (context == view->context)
|
|
|
|
return;
|
|
|
|
|
2002-10-09 11:49:01 +00:00
|
|
|
if (view->context)
|
2001-02-07 15:01:52 +00:00
|
|
|
{
|
2002-10-09 11:49:01 +00:00
|
|
|
if (view->container)
|
|
|
|
{
|
2003-01-05 22:07:10 +00:00
|
|
|
g_signal_handlers_disconnect_by_func (view->context,
|
2002-10-09 11:49:01 +00:00
|
|
|
gimp_container_view_context_changed,
|
|
|
|
view);
|
|
|
|
|
|
|
|
if (view->dnd_widget)
|
|
|
|
{
|
|
|
|
gtk_drag_dest_unset (GTK_WIDGET (view->dnd_widget));
|
|
|
|
gimp_dnd_viewable_dest_remove (GTK_WIDGET (view->dnd_widget),
|
|
|
|
view->container->children_type);
|
|
|
|
}
|
|
|
|
}
|
2001-02-18 19:44:28 +00:00
|
|
|
|
2003-01-05 22:07:10 +00:00
|
|
|
g_object_unref (view->context);
|
2001-02-07 15:01:52 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
view->context = context;
|
|
|
|
|
2002-10-09 11:49:01 +00:00
|
|
|
if (view->context)
|
2001-02-07 15:01:52 +00:00
|
|
|
{
|
2003-01-05 22:07:10 +00:00
|
|
|
g_object_ref (view->context);
|
2001-02-07 15:01:52 +00:00
|
|
|
|
2002-10-09 11:49:01 +00:00
|
|
|
if (view->container)
|
|
|
|
{
|
|
|
|
GimpObject *object;
|
|
|
|
const gchar *signal_name;
|
2001-02-07 15:01:52 +00:00
|
|
|
|
2002-10-09 11:49:01 +00:00
|
|
|
signal_name =
|
|
|
|
gimp_context_type_to_signal_name (view->container->children_type);
|
2001-02-07 15:01:52 +00:00
|
|
|
|
2003-01-05 22:07:10 +00:00
|
|
|
g_signal_connect_object (view->context, signal_name,
|
2002-10-09 11:49:01 +00:00
|
|
|
G_CALLBACK (gimp_container_view_context_changed),
|
2003-01-05 22:07:10 +00:00
|
|
|
view,
|
2002-10-09 11:49:01 +00:00
|
|
|
0);
|
2001-02-07 15:01:52 +00:00
|
|
|
|
2002-10-09 11:49:01 +00:00
|
|
|
object = gimp_context_get_by_type (view->context,
|
|
|
|
view->container->children_type);
|
|
|
|
|
2003-03-16 11:14:29 +00:00
|
|
|
gimp_container_view_select_item (view, (GimpViewable *) object);
|
2001-02-18 19:44:28 +00:00
|
|
|
|
2002-10-09 11:49:01 +00:00
|
|
|
if (view->dnd_widget)
|
|
|
|
gimp_dnd_viewable_dest_add (GTK_WIDGET (view->dnd_widget),
|
|
|
|
view->container->children_type,
|
|
|
|
gimp_container_view_viewable_dropped,
|
|
|
|
view);
|
|
|
|
}
|
2001-02-05 19:10:40 +00:00
|
|
|
}
|
2003-12-21 16:11:06 +00:00
|
|
|
|
|
|
|
g_object_notify (G_OBJECT (view), "context");
|
2001-02-05 19:10:40 +00:00
|
|
|
}
|
|
|
|
|
2001-02-05 23:14:14 +00:00
|
|
|
void
|
|
|
|
gimp_container_view_set_preview_size (GimpContainerView *view,
|
2003-04-08 12:39:02 +00:00
|
|
|
gint preview_size,
|
|
|
|
gint preview_border_width)
|
2001-02-05 23:14:14 +00:00
|
|
|
{
|
|
|
|
g_return_if_fail (GIMP_IS_CONTAINER_VIEW (view));
|
2003-04-01 13:53:47 +00:00
|
|
|
g_return_if_fail (preview_size > 0 &&
|
|
|
|
preview_size <= GIMP_VIEWABLE_MAX_PREVIEW_SIZE);
|
2003-04-08 12:39:02 +00:00
|
|
|
g_return_if_fail (preview_border_width >= 0 &&
|
|
|
|
preview_border_width <= GIMP_PREVIEW_MAX_BORDER_WIDTH);
|
2001-02-05 23:14:14 +00:00
|
|
|
|
2003-04-08 12:39:02 +00:00
|
|
|
if (view->preview_size != preview_size ||
|
|
|
|
view->preview_border_width != preview_border_width)
|
2001-08-07 12:42:23 +00:00
|
|
|
{
|
2003-04-08 12:39:02 +00:00
|
|
|
view->preview_size = preview_size;
|
|
|
|
view->preview_border_width = preview_border_width;
|
2001-05-03 22:19:17 +00:00
|
|
|
|
2001-08-07 12:42:23 +00:00
|
|
|
GIMP_CONTAINER_VIEW_GET_CLASS (view)->set_preview_size (view);
|
|
|
|
}
|
2001-05-03 22:19:17 +00:00
|
|
|
}
|
2001-02-05 23:14:14 +00:00
|
|
|
|
2001-08-04 20:38:54 +00:00
|
|
|
void
|
|
|
|
gimp_container_view_enable_dnd (GimpContainerView *view,
|
|
|
|
GtkButton *button,
|
|
|
|
GType children_type)
|
|
|
|
{
|
|
|
|
g_return_if_fail (GIMP_IS_CONTAINER_VIEW (view));
|
|
|
|
g_return_if_fail (GTK_IS_BUTTON (button));
|
|
|
|
|
2002-09-02 14:39:08 +00:00
|
|
|
gimp_dnd_viewable_dest_add (GTK_WIDGET (button),
|
2001-08-04 20:38:54 +00:00
|
|
|
children_type,
|
|
|
|
gimp_container_view_button_viewable_dropped,
|
|
|
|
view);
|
|
|
|
}
|
|
|
|
|
2003-05-18 13:28:27 +00:00
|
|
|
gboolean
|
2001-02-07 15:01:52 +00:00
|
|
|
gimp_container_view_select_item (GimpContainerView *view,
|
|
|
|
GimpViewable *viewable)
|
|
|
|
{
|
2003-05-18 13:28:27 +00:00
|
|
|
gboolean success = FALSE;
|
|
|
|
|
|
|
|
g_return_val_if_fail (GIMP_IS_CONTAINER_VIEW (view), FALSE);
|
|
|
|
g_return_val_if_fail (viewable == NULL || GIMP_IS_VIEWABLE (viewable), FALSE);
|
2001-02-07 15:01:52 +00:00
|
|
|
|
2003-03-22 16:26:11 +00:00
|
|
|
if (view->hash_table)
|
|
|
|
{
|
|
|
|
gpointer insert_data;
|
|
|
|
|
|
|
|
insert_data = g_hash_table_lookup (view->hash_table, viewable);
|
2001-02-07 15:01:52 +00:00
|
|
|
|
2003-03-22 16:26:11 +00:00
|
|
|
g_signal_emit (view, view_signals[SELECT_ITEM], 0,
|
2003-05-18 13:28:27 +00:00
|
|
|
viewable, insert_data, &success);
|
2003-03-22 16:26:11 +00:00
|
|
|
}
|
2003-05-18 13:28:27 +00:00
|
|
|
|
|
|
|
return success;
|
2001-02-07 15:01:52 +00:00
|
|
|
}
|
|
|
|
|
2001-02-18 19:44:28 +00:00
|
|
|
void
|
|
|
|
gimp_container_view_activate_item (GimpContainerView *view,
|
|
|
|
GimpViewable *viewable)
|
|
|
|
{
|
|
|
|
g_return_if_fail (GIMP_IS_CONTAINER_VIEW (view));
|
|
|
|
g_return_if_fail (GIMP_IS_VIEWABLE (viewable));
|
|
|
|
|
2003-03-22 16:26:11 +00:00
|
|
|
if (view->hash_table)
|
|
|
|
{
|
|
|
|
gpointer insert_data;
|
|
|
|
|
|
|
|
insert_data = g_hash_table_lookup (view->hash_table, viewable);
|
2001-02-18 19:44:28 +00:00
|
|
|
|
2003-03-22 16:26:11 +00:00
|
|
|
g_signal_emit (view, view_signals[ACTIVATE_ITEM], 0,
|
|
|
|
viewable, insert_data);
|
|
|
|
}
|
2001-02-18 19:44:28 +00:00
|
|
|
}
|
|
|
|
|
2001-04-29 15:23:01 +00:00
|
|
|
void
|
|
|
|
gimp_container_view_context_item (GimpContainerView *view,
|
|
|
|
GimpViewable *viewable)
|
|
|
|
{
|
|
|
|
g_return_if_fail (GIMP_IS_CONTAINER_VIEW (view));
|
|
|
|
g_return_if_fail (GIMP_IS_VIEWABLE (viewable));
|
|
|
|
|
2003-03-22 16:26:11 +00:00
|
|
|
if (view->hash_table)
|
|
|
|
{
|
|
|
|
gpointer insert_data;
|
|
|
|
|
|
|
|
insert_data = g_hash_table_lookup (view->hash_table, viewable);
|
2001-04-29 15:23:01 +00:00
|
|
|
|
2003-03-22 16:26:11 +00:00
|
|
|
g_signal_emit (view, view_signals[CONTEXT_ITEM], 0,
|
|
|
|
viewable, insert_data);
|
|
|
|
}
|
2001-04-29 15:23:01 +00:00
|
|
|
}
|
|
|
|
|
2003-05-18 13:28:27 +00:00
|
|
|
gboolean
|
2001-02-07 15:01:52 +00:00
|
|
|
gimp_container_view_item_selected (GimpContainerView *view,
|
|
|
|
GimpViewable *viewable)
|
|
|
|
{
|
2003-05-18 13:28:27 +00:00
|
|
|
gboolean success;
|
2001-02-07 15:01:52 +00:00
|
|
|
|
2003-05-18 13:28:27 +00:00
|
|
|
g_return_val_if_fail (GIMP_IS_CONTAINER_VIEW (view), FALSE);
|
|
|
|
g_return_val_if_fail (GIMP_IS_VIEWABLE (viewable), FALSE);
|
2003-03-22 16:26:11 +00:00
|
|
|
|
2003-05-18 13:28:27 +00:00
|
|
|
success = gimp_container_view_select_item (view, viewable);
|
|
|
|
|
|
|
|
if (success && view->container && view->context)
|
2003-03-22 16:26:11 +00:00
|
|
|
{
|
|
|
|
GimpContext *context;
|
2001-02-07 15:01:52 +00:00
|
|
|
|
2003-03-22 16:26:11 +00:00
|
|
|
/* ref and remember the context because view->context may
|
|
|
|
* become NULL by calling gimp_context_set_by_type()
|
|
|
|
*/
|
|
|
|
context = g_object_ref (view->context);
|
|
|
|
|
|
|
|
g_signal_handlers_block_by_func (context,
|
|
|
|
gimp_container_view_context_changed,
|
|
|
|
view);
|
|
|
|
|
|
|
|
gimp_context_set_by_type (context,
|
|
|
|
view->container->children_type,
|
|
|
|
GIMP_OBJECT (viewable));
|
|
|
|
|
|
|
|
g_signal_handlers_unblock_by_func (context,
|
|
|
|
gimp_container_view_context_changed,
|
|
|
|
view);
|
|
|
|
|
|
|
|
g_object_unref (context);
|
|
|
|
}
|
2003-05-18 13:28:27 +00:00
|
|
|
|
|
|
|
return success;
|
2001-02-07 15:01:52 +00:00
|
|
|
}
|
|
|
|
|
2001-02-18 19:44:28 +00:00
|
|
|
void
|
2001-02-27 14:14:13 +00:00
|
|
|
gimp_container_view_item_activated (GimpContainerView *view,
|
|
|
|
GimpViewable *viewable)
|
2001-02-18 19:44:28 +00:00
|
|
|
{
|
|
|
|
g_return_if_fail (GIMP_IS_CONTAINER_VIEW (view));
|
|
|
|
g_return_if_fail (GIMP_IS_VIEWABLE (viewable));
|
|
|
|
|
|
|
|
gimp_container_view_activate_item (view, viewable);
|
|
|
|
}
|
|
|
|
|
2001-04-29 15:23:01 +00:00
|
|
|
void
|
|
|
|
gimp_container_view_item_context (GimpContainerView *view,
|
|
|
|
GimpViewable *viewable)
|
|
|
|
{
|
|
|
|
g_return_if_fail (GIMP_IS_CONTAINER_VIEW (view));
|
|
|
|
g_return_if_fail (GIMP_IS_VIEWABLE (viewable));
|
|
|
|
|
|
|
|
gimp_container_view_context_item (view, viewable);
|
|
|
|
}
|
|
|
|
|
2001-02-05 19:10:40 +00:00
|
|
|
static void
|
2001-02-08 04:16:41 +00:00
|
|
|
gimp_container_view_clear_items (GimpContainerView *view)
|
2001-02-05 19:10:40 +00:00
|
|
|
{
|
2001-08-07 12:42:23 +00:00
|
|
|
GIMP_CONTAINER_VIEW_GET_CLASS (view)->clear_items (view);
|
2001-02-05 19:10:40 +00:00
|
|
|
}
|
|
|
|
|
2001-02-08 04:16:41 +00:00
|
|
|
static void
|
|
|
|
gimp_container_view_real_clear_items (GimpContainerView *view)
|
|
|
|
{
|
2003-03-06 16:47:34 +00:00
|
|
|
GimpContainerViewClass *view_class;
|
|
|
|
|
|
|
|
view_class = GIMP_CONTAINER_VIEW_GET_CLASS (view);
|
|
|
|
|
2001-02-08 04:16:41 +00:00
|
|
|
g_hash_table_destroy (view->hash_table);
|
|
|
|
|
2003-03-06 16:47:34 +00:00
|
|
|
view->hash_table = g_hash_table_new_full (g_direct_hash, g_direct_equal,
|
|
|
|
NULL,
|
|
|
|
view_class->insert_data_free);
|
2001-02-08 04:16:41 +00:00
|
|
|
}
|
|
|
|
|
2001-02-05 19:10:40 +00:00
|
|
|
static void
|
|
|
|
gimp_container_view_add_foreach (GimpViewable *viewable,
|
|
|
|
GimpContainerView *view)
|
|
|
|
{
|
2001-08-07 12:42:23 +00:00
|
|
|
gpointer insert_data;
|
2001-02-05 19:10:40 +00:00
|
|
|
|
2001-08-07 12:42:23 +00:00
|
|
|
insert_data = GIMP_CONTAINER_VIEW_GET_CLASS (view)->insert_item (view,
|
|
|
|
viewable,
|
|
|
|
-1);
|
2001-02-05 19:10:40 +00:00
|
|
|
|
|
|
|
g_hash_table_insert (view->hash_table, viewable, insert_data);
|
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
gimp_container_view_add (GimpContainerView *view,
|
|
|
|
GimpViewable *viewable,
|
|
|
|
GimpContainer *container)
|
|
|
|
{
|
|
|
|
gpointer insert_data = NULL;
|
|
|
|
gint index;
|
|
|
|
|
2003-10-18 16:23:15 +00:00
|
|
|
if (gimp_container_frozen (container))
|
|
|
|
return;
|
|
|
|
|
2001-02-05 19:10:40 +00:00
|
|
|
index = gimp_container_get_child_index (container,
|
|
|
|
GIMP_OBJECT (viewable));
|
|
|
|
|
2001-08-07 12:42:23 +00:00
|
|
|
insert_data = GIMP_CONTAINER_VIEW_GET_CLASS (view)->insert_item (view,
|
|
|
|
viewable,
|
|
|
|
index);
|
2001-02-05 19:10:40 +00:00
|
|
|
|
|
|
|
g_hash_table_insert (view->hash_table, viewable, insert_data);
|
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
gimp_container_view_remove (GimpContainerView *view,
|
|
|
|
GimpViewable *viewable,
|
|
|
|
GimpContainer *container)
|
|
|
|
{
|
|
|
|
gpointer insert_data;
|
|
|
|
|
2003-10-18 16:23:15 +00:00
|
|
|
if (gimp_container_frozen (container))
|
|
|
|
return;
|
|
|
|
|
2001-02-05 19:10:40 +00:00
|
|
|
insert_data = g_hash_table_lookup (view->hash_table, viewable);
|
|
|
|
|
|
|
|
if (insert_data)
|
|
|
|
{
|
2001-08-07 12:42:23 +00:00
|
|
|
GIMP_CONTAINER_VIEW_GET_CLASS (view)->remove_item (view,
|
|
|
|
viewable,
|
|
|
|
insert_data);
|
2003-02-25 03:19:55 +00:00
|
|
|
|
|
|
|
g_hash_table_remove (view->hash_table, viewable);
|
2001-02-05 19:10:40 +00:00
|
|
|
}
|
|
|
|
}
|
2001-02-07 15:01:52 +00:00
|
|
|
|
2001-02-17 21:20:10 +00:00
|
|
|
static void
|
|
|
|
gimp_container_view_reorder (GimpContainerView *view,
|
|
|
|
GimpViewable *viewable,
|
|
|
|
gint new_index,
|
|
|
|
GimpContainer *container)
|
|
|
|
{
|
|
|
|
gpointer insert_data;
|
|
|
|
|
2003-10-18 16:23:15 +00:00
|
|
|
if (gimp_container_frozen (container))
|
|
|
|
return;
|
|
|
|
|
2001-02-17 21:20:10 +00:00
|
|
|
insert_data = g_hash_table_lookup (view->hash_table, viewable);
|
|
|
|
|
|
|
|
if (insert_data)
|
|
|
|
{
|
2001-08-07 12:42:23 +00:00
|
|
|
GIMP_CONTAINER_VIEW_GET_CLASS (view)->reorder_item (view,
|
|
|
|
viewable,
|
|
|
|
new_index,
|
|
|
|
insert_data);
|
2001-02-17 21:20:10 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2003-10-18 16:23:15 +00:00
|
|
|
static void
|
|
|
|
gimp_container_view_freeze (GimpContainerView *view,
|
|
|
|
GimpContainer *container)
|
|
|
|
{
|
|
|
|
gimp_container_view_clear_items (view);
|
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
gimp_container_view_thaw (GimpContainerView *view,
|
|
|
|
GimpContainer *container)
|
|
|
|
{
|
|
|
|
gimp_container_foreach (view->container,
|
|
|
|
(GFunc) gimp_container_view_add_foreach,
|
|
|
|
view);
|
|
|
|
|
|
|
|
if (view->context)
|
|
|
|
{
|
|
|
|
GimpObject *object;
|
|
|
|
|
|
|
|
object = gimp_context_get_by_type (view->context,
|
|
|
|
view->container->children_type);
|
|
|
|
|
|
|
|
gimp_container_view_select_item (view, (GimpViewable *) object);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2004-01-29 16:34:41 +00:00
|
|
|
static void
|
|
|
|
gimp_container_view_name_changed (GimpViewable *viewable,
|
|
|
|
GimpContainerView *view)
|
|
|
|
{
|
|
|
|
gpointer insert_data;
|
|
|
|
|
|
|
|
insert_data = g_hash_table_lookup (view->hash_table, viewable);
|
|
|
|
|
|
|
|
if (insert_data)
|
|
|
|
{
|
|
|
|
GIMP_CONTAINER_VIEW_GET_CLASS (view)->rename_item (view,
|
|
|
|
viewable,
|
|
|
|
insert_data);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2001-02-07 15:01:52 +00:00
|
|
|
static void
|
|
|
|
gimp_container_view_context_changed (GimpContext *context,
|
|
|
|
GimpViewable *viewable,
|
|
|
|
GimpContainerView *view)
|
|
|
|
{
|
|
|
|
gpointer insert_data;
|
2003-05-18 13:28:27 +00:00
|
|
|
gboolean success = FALSE;
|
2001-02-07 15:01:52 +00:00
|
|
|
|
|
|
|
insert_data = g_hash_table_lookup (view->hash_table, viewable);
|
|
|
|
|
2003-05-18 13:28:27 +00:00
|
|
|
g_signal_emit (view, view_signals[SELECT_ITEM], 0,
|
|
|
|
viewable, insert_data, &success);
|
|
|
|
|
|
|
|
if (! success)
|
|
|
|
g_warning ("gimp_container_view_context_changed(): select_item() failed "
|
|
|
|
"(should not happen)");
|
2001-02-07 15:01:52 +00:00
|
|
|
}
|
2001-02-18 19:44:28 +00:00
|
|
|
|
|
|
|
static void
|
2001-08-04 20:38:54 +00:00
|
|
|
gimp_container_view_viewable_dropped (GtkWidget *widget,
|
|
|
|
GimpViewable *viewable,
|
|
|
|
gpointer data)
|
2001-02-18 19:44:28 +00:00
|
|
|
{
|
2004-05-10 11:08:51 +00:00
|
|
|
GimpContainerView *view = GIMP_CONTAINER_VIEW (data);
|
2001-02-18 19:44:28 +00:00
|
|
|
|
|
|
|
gimp_context_set_by_type (view->context,
|
|
|
|
view->container->children_type,
|
|
|
|
GIMP_OBJECT (viewable));
|
|
|
|
}
|
2001-08-04 20:38:54 +00:00
|
|
|
|
|
|
|
static void
|
|
|
|
gimp_container_view_button_viewable_dropped (GtkWidget *widget,
|
|
|
|
GimpViewable *viewable,
|
|
|
|
gpointer data)
|
|
|
|
{
|
2004-05-10 11:08:51 +00:00
|
|
|
GimpContainerView *view = GIMP_CONTAINER_VIEW (data);
|
2001-08-04 20:38:54 +00:00
|
|
|
|
|
|
|
if (viewable && gimp_container_have (view->container,
|
|
|
|
GIMP_OBJECT (viewable)))
|
|
|
|
{
|
|
|
|
gimp_container_view_item_selected (view, viewable);
|
|
|
|
|
|
|
|
gtk_button_clicked (GTK_BUTTON (widget));
|
|
|
|
}
|
|
|
|
}
|