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

new prefs. page "Help System" because there will soon be more widgets

1999-11-20  Michael Natterer  <mitch@gimp.org>

	* app/preferences_dialog.c: new prefs. page "Help System" because
	there will soon be more widgets there (browser selection etc.)
	Cleaned up the "Display" and "Interface" pages a bit.

	* app/menus.c
	* plug-ins/common/plugindetails.c: add "...".

	* libgimp/gimpfileselection.c
	* libgimp/gimppatheditor.c: a widget shouldn't connect to it's own
	"realize" signal. Set widget_class->realize = <widget>_realize
	instead.
parent e46eaf86
1999-11-20 Michael Natterer <mitch@gimp.org>
* app/preferences_dialog.c: new prefs. page "Help System" because
there will soon be more widgets there (browser selection etc.)
Cleaned up the "Display" and "Interface" pages a bit.
* app/menus.c
* plug-ins/common/plugindetails.c: add "...".
* libgimp/gimpfileselection.c
* libgimp/gimppatheditor.c: a widget shouldn't connect to it's own
"realize" signal. Set widget_class->realize = <widget>_realize
instead.
1999-11-20 Michael Natterer <mitch@gimp.org>
Reorganized the core menu items (everything except
......
......@@ -1423,10 +1423,15 @@ file_pref_cmd_callback (GtkWidget *widget,
gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, FALSE, 0);
gtk_widget_show (frame);
vbox2 = gtk_vbox_new (FALSE, 2);
gtk_container_set_border_width (GTK_CONTAINER (vbox2), 2);
gtk_container_add (GTK_CONTAINER (frame), vbox2);
gtk_widget_show (vbox2);
hbox = gtk_hbox_new (FALSE, 2);
gtk_container_add (GTK_CONTAINER (frame), hbox);
gtk_widget_show (hbox);
table = gtk_table_new (1, 2, FALSE);
gtk_container_set_border_width (GTK_CONTAINER (table), 2);
gtk_table_set_col_spacings (GTK_TABLE (table), 4);
gtk_box_pack_start (GTK_BOX (hbox), table, FALSE, FALSE, 0);
gtk_widget_show (table);
optionmenu =
gimp_option_menu_new (file_prefs_toggle_callback,
......@@ -1438,10 +1443,9 @@ file_pref_cmd_callback (GtkWidget *widget,
_("Cubic"), &interpolation_type,
(gpointer) CUBIC_INTERPOLATION,
NULL);
gtk_box_pack_start (GTK_BOX (vbox2), optionmenu, FALSE, FALSE, 0);
gtk_widget_show (optionmenu);
gimp_table_attach_aligned (GTK_TABLE (table), 0,
_("Interpolation Type:"), 1.0, 0.5,
optionmenu, TRUE);
/* Interface */
vbox = file_prefs_notebook_append_page (GTK_NOTEBOOK (notebook),
......@@ -1515,15 +1519,6 @@ file_pref_cmd_callback (GtkWidget *widget,
gimp_table_attach_aligned (GTK_TABLE (table), 2,
_("Levels of Undo:"), 1.0, 0.5, spinbutton, TRUE);
button = gtk_check_button_new_with_label (_("Nav window per display"));
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button),
edit_nav_window_per_display);
gtk_box_pack_start (GTK_BOX (vbox2), button, FALSE, FALSE, 0);
gtk_signal_connect (GTK_OBJECT (button), "toggled",
(GtkSignalFunc) file_prefs_toggle_callback,
&edit_nav_window_per_display);
gtk_widget_show (button);
spinbutton =
gimp_spin_button_new (&adjustment, edit_last_opened_size,
0.0, 16.0, 1.0, 5.0, 0.0, 1.0, 0.0);
......@@ -1534,7 +1529,36 @@ file_pref_cmd_callback (GtkWidget *widget,
_("Recent Documents List Size:"), 1.0, 0.5,
spinbutton, TRUE);
frame = gtk_frame_new (_("Help System"));
frame = gtk_frame_new (_("Dialog Behaviour"));
gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, FALSE, 0);
gtk_widget_show (frame);
vbox2 = gtk_vbox_new (FALSE, 2);
gtk_container_set_border_width (GTK_CONTAINER (vbox2), 2);
gtk_container_add (GTK_CONTAINER (frame), vbox2);
gtk_widget_show (vbox2);
button = gtk_check_button_new_with_label (_("Navigation Window per Display"));
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button),
edit_nav_window_per_display);
gtk_box_pack_start (GTK_BOX (vbox2), button, FALSE, FALSE, 0);
gtk_signal_connect (GTK_OBJECT (button), "toggled",
(GtkSignalFunc) file_prefs_toggle_callback,
&edit_nav_window_per_display);
gtk_widget_show (button);
/* Interface / Help System */
vbox = file_prefs_notebook_append_page (GTK_NOTEBOOK (notebook),
_("Help System Settings"),
GTK_CTREE (ctree),
_("Help System"),
top_insert,
&child_insert,
page_index);
gtk_widget_show (vbox);
page_index++;
frame = gtk_frame_new (_("General"));
gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, FALSE, 0);
gtk_widget_show (frame);
......
......@@ -913,7 +913,7 @@ menus_reorder_plugins (void)
{
static gchar *xtns_plugins[] = { "/Xtns/DB Browser...",
"/Xtns/PDB Explorer",
"/Xtns/Plugin Details",
"/Xtns/Plugin Details...",
"/Xtns/Parasite Editor" };
static gint n_xtns_plugins = (sizeof (xtns_plugins) /
sizeof (xtns_plugins[0]));
......
......@@ -1423,10 +1423,15 @@ file_pref_cmd_callback (GtkWidget *widget,
gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, FALSE, 0);
gtk_widget_show (frame);
vbox2 = gtk_vbox_new (FALSE, 2);
gtk_container_set_border_width (GTK_CONTAINER (vbox2), 2);
gtk_container_add (GTK_CONTAINER (frame), vbox2);
gtk_widget_show (vbox2);
hbox = gtk_hbox_new (FALSE, 2);
gtk_container_add (GTK_CONTAINER (frame), hbox);
gtk_widget_show (hbox);
table = gtk_table_new (1, 2, FALSE);
gtk_container_set_border_width (GTK_CONTAINER (table), 2);
gtk_table_set_col_spacings (GTK_TABLE (table), 4);
gtk_box_pack_start (GTK_BOX (hbox), table, FALSE, FALSE, 0);
gtk_widget_show (table);
optionmenu =
gimp_option_menu_new (file_prefs_toggle_callback,
......@@ -1438,10 +1443,9 @@ file_pref_cmd_callback (GtkWidget *widget,
_("Cubic"), &interpolation_type,
(gpointer) CUBIC_INTERPOLATION,
NULL);
gtk_box_pack_start (GTK_BOX (vbox2), optionmenu, FALSE, FALSE, 0);
gtk_widget_show (optionmenu);
gimp_table_attach_aligned (GTK_TABLE (table), 0,
_("Interpolation Type:"), 1.0, 0.5,
optionmenu, TRUE);
/* Interface */
vbox = file_prefs_notebook_append_page (GTK_NOTEBOOK (notebook),
......@@ -1515,15 +1519,6 @@ file_pref_cmd_callback (GtkWidget *widget,
gimp_table_attach_aligned (GTK_TABLE (table), 2,
_("Levels of Undo:"), 1.0, 0.5, spinbutton, TRUE);
button = gtk_check_button_new_with_label (_("Nav window per display"));
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button),
edit_nav_window_per_display);
gtk_box_pack_start (GTK_BOX (vbox2), button, FALSE, FALSE, 0);
gtk_signal_connect (GTK_OBJECT (button), "toggled",
(GtkSignalFunc) file_prefs_toggle_callback,
&edit_nav_window_per_display);
gtk_widget_show (button);
spinbutton =
gimp_spin_button_new (&adjustment, edit_last_opened_size,
0.0, 16.0, 1.0, 5.0, 0.0, 1.0, 0.0);
......@@ -1534,7 +1529,36 @@ file_pref_cmd_callback (GtkWidget *widget,
_("Recent Documents List Size:"), 1.0, 0.5,
spinbutton, TRUE);
frame = gtk_frame_new (_("Help System"));
frame = gtk_frame_new (_("Dialog Behaviour"));
gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, FALSE, 0);
gtk_widget_show (frame);
vbox2 = gtk_vbox_new (FALSE, 2);
gtk_container_set_border_width (GTK_CONTAINER (vbox2), 2);
gtk_container_add (GTK_CONTAINER (frame), vbox2);
gtk_widget_show (vbox2);
button = gtk_check_button_new_with_label (_("Navigation Window per Display"));
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button),
edit_nav_window_per_display);
gtk_box_pack_start (GTK_BOX (vbox2), button, FALSE, FALSE, 0);
gtk_signal_connect (GTK_OBJECT (button), "toggled",
(GtkSignalFunc) file_prefs_toggle_callback,
&edit_nav_window_per_display);
gtk_widget_show (button);
/* Interface / Help System */
vbox = file_prefs_notebook_append_page (GTK_NOTEBOOK (notebook),
_("Help System Settings"),
GTK_CTREE (ctree),
_("Help System"),
top_insert,
&child_insert,
page_index);
gtk_widget_show (vbox);
page_index++;
frame = gtk_frame_new (_("General"));
gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, FALSE, 0);
gtk_widget_show (frame);
......
......@@ -913,7 +913,7 @@ menus_reorder_plugins (void)
{
static gchar *xtns_plugins[] = { "/Xtns/DB Browser...",
"/Xtns/PDB Explorer",
"/Xtns/Plugin Details",
"/Xtns/Plugin Details...",
"/Xtns/Parasite Editor" };
static gint n_xtns_plugins = (sizeof (xtns_plugins) /
sizeof (xtns_plugins[0]));
......
......@@ -913,7 +913,7 @@ menus_reorder_plugins (void)
{
static gchar *xtns_plugins[] = { "/Xtns/DB Browser...",
"/Xtns/PDB Explorer",
"/Xtns/Plugin Details",
"/Xtns/Plugin Details...",
"/Xtns/Parasite Editor" };
static gint n_xtns_plugins = (sizeof (xtns_plugins) /
sizeof (xtns_plugins[0]));
......
......@@ -1423,10 +1423,15 @@ file_pref_cmd_callback (GtkWidget *widget,
gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, FALSE, 0);
gtk_widget_show (frame);
vbox2 = gtk_vbox_new (FALSE, 2);
gtk_container_set_border_width (GTK_CONTAINER (vbox2), 2);
gtk_container_add (GTK_CONTAINER (frame), vbox2);
gtk_widget_show (vbox2);
hbox = gtk_hbox_new (FALSE, 2);
gtk_container_add (GTK_CONTAINER (frame), hbox);
gtk_widget_show (hbox);
table = gtk_table_new (1, 2, FALSE);
gtk_container_set_border_width (GTK_CONTAINER (table), 2);
gtk_table_set_col_spacings (GTK_TABLE (table), 4);
gtk_box_pack_start (GTK_BOX (hbox), table, FALSE, FALSE, 0);
gtk_widget_show (table);
optionmenu =
gimp_option_menu_new (file_prefs_toggle_callback,
......@@ -1438,10 +1443,9 @@ file_pref_cmd_callback (GtkWidget *widget,
_("Cubic"), &interpolation_type,
(gpointer) CUBIC_INTERPOLATION,
NULL);
gtk_box_pack_start (GTK_BOX (vbox2), optionmenu, FALSE, FALSE, 0);
gtk_widget_show (optionmenu);
gimp_table_attach_aligned (GTK_TABLE (table), 0,
_("Interpolation Type:"), 1.0, 0.5,
optionmenu, TRUE);
/* Interface */
vbox = file_prefs_notebook_append_page (GTK_NOTEBOOK (notebook),
......@@ -1515,15 +1519,6 @@ file_pref_cmd_callback (GtkWidget *widget,
gimp_table_attach_aligned (GTK_TABLE (table), 2,
_("Levels of Undo:"), 1.0, 0.5, spinbutton, TRUE);
button = gtk_check_button_new_with_label (_("Nav window per display"));
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button),
edit_nav_window_per_display);
gtk_box_pack_start (GTK_BOX (vbox2), button, FALSE, FALSE, 0);
gtk_signal_connect (GTK_OBJECT (button), "toggled",
(GtkSignalFunc) file_prefs_toggle_callback,
&edit_nav_window_per_display);
gtk_widget_show (button);
spinbutton =
gimp_spin_button_new (&adjustment, edit_last_opened_size,
0.0, 16.0, 1.0, 5.0, 0.0, 1.0, 0.0);
......@@ -1534,7 +1529,36 @@ file_pref_cmd_callback (GtkWidget *widget,
_("Recent Documents List Size:"), 1.0, 0.5,
spinbutton, TRUE);
frame = gtk_frame_new (_("Help System"));
frame = gtk_frame_new (_("Dialog Behaviour"));
gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, FALSE, 0);
gtk_widget_show (frame);
vbox2 = gtk_vbox_new (FALSE, 2);
gtk_container_set_border_width (GTK_CONTAINER (vbox2), 2);
gtk_container_add (GTK_CONTAINER (frame), vbox2);
gtk_widget_show (vbox2);
button = gtk_check_button_new_with_label (_("Navigation Window per Display"));
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button),
edit_nav_window_per_display);
gtk_box_pack_start (GTK_BOX (vbox2), button, FALSE, FALSE, 0);
gtk_signal_connect (GTK_OBJECT (button), "toggled",
(GtkSignalFunc) file_prefs_toggle_callback,
&edit_nav_window_per_display);
gtk_widget_show (button);
/* Interface / Help System */
vbox = file_prefs_notebook_append_page (GTK_NOTEBOOK (notebook),
_("Help System Settings"),
GTK_CTREE (ctree),
_("Help System"),
top_insert,
&child_insert,
page_index);
gtk_widget_show (vbox);
page_index++;
frame = gtk_frame_new (_("General"));
gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, FALSE, 0);
gtk_widget_show (frame);
......
......@@ -913,7 +913,7 @@ menus_reorder_plugins (void)
{
static gchar *xtns_plugins[] = { "/Xtns/DB Browser...",
"/Xtns/PDB Explorer",
"/Xtns/Plugin Details",
"/Xtns/Plugin Details...",
"/Xtns/Parasite Editor" };
static gint n_xtns_plugins = (sizeof (xtns_plugins) /
sizeof (xtns_plugins[0]));
......
......@@ -19,7 +19,6 @@
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#include "config.h"
#include <glib.h> /* Needed here by Win32 gcc compilation */
......@@ -48,7 +47,7 @@
#endif
/* callbacks */
static void gimp_file_selection_realize (GtkWidget *, gpointer);
static void gimp_file_selection_realize (GtkWidget *);
static void gimp_file_selection_entry_callback (GtkWidget *, gpointer);
static int gimp_file_selection_entry_focus_out_callback (GtkWidget *,
GdkEvent *, gpointer);
......@@ -57,7 +56,8 @@ static void gimp_file_selection_browse_callback (GtkWidget *, gpointer);
/* private functions */
static void gimp_file_selection_check_filename (GimpFileSelection *gfs);
enum {
enum
{
FILENAME_CHANGED,
LAST_SIGNAL
};
......@@ -90,18 +90,20 @@ static void
gimp_file_selection_class_init (GimpFileSelectionClass *class)
{
GtkObjectClass *object_class;
GtkWidgetClass *widget_class;
object_class = (GtkObjectClass*) class;
object_class = (GtkObjectClass *) class;
widget_class = (GtkWidgetClass *) class;
parent_class = gtk_type_class (gtk_hbox_get_type ());
gimp_file_selection_signals[FILENAME_CHANGED] =
gtk_signal_new ("filename_changed",
GTK_RUN_FIRST,
object_class->type,
GTK_SIGNAL_OFFSET (GimpFileSelectionClass,
filename_changed),
gtk_signal_default_marshaller, GTK_TYPE_NONE, 0);
gtk_signal_new ("filename_changed",
GTK_RUN_FIRST,
object_class->type,
GTK_SIGNAL_OFFSET (GimpFileSelectionClass,
filename_changed),
gtk_signal_default_marshaller, GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, gimp_file_selection_signals,
LAST_SIGNAL);
......@@ -109,6 +111,8 @@ gimp_file_selection_class_init (GimpFileSelectionClass *class)
class->filename_changed = NULL;
object_class->destroy = gimp_file_selection_destroy;
widget_class->realize = gimp_file_selection_realize;
}
static void
......@@ -125,20 +129,19 @@ gimp_file_selection_init (GimpFileSelection *gfs)
gfs->browse_button = gtk_button_new_with_label (" ... ");
gtk_box_pack_end (GTK_BOX (gfs), gfs->browse_button, FALSE, FALSE, 0);
gtk_signal_connect (GTK_OBJECT(gfs->browse_button), "clicked",
GTK_SIGNAL_FUNC(gimp_file_selection_browse_callback), gfs);
GTK_SIGNAL_FUNC (gimp_file_selection_browse_callback),
gfs);
gtk_widget_show (gfs->browse_button);
gfs->entry = gtk_entry_new ();
gtk_box_pack_end (GTK_BOX (gfs), gfs->entry, TRUE, TRUE, 0);
gtk_signal_connect (GTK_OBJECT(gfs->entry), "activate",
(GtkSignalFunc) gimp_file_selection_entry_callback, gfs);
gtk_signal_connect (GTK_OBJECT(gfs->entry), "focus_out_event",
(GdkEventFunc) gimp_file_selection_entry_focus_out_callback, gfs);
gtk_signal_connect (GTK_OBJECT (gfs->entry), "activate",
GTK_SIGNAL_FUNC (gimp_file_selection_entry_callback),
gfs);
gtk_signal_connect (GTK_OBJECT (gfs->entry), "focus_out_event",
GTK_SIGNAL_FUNC (gimp_file_selection_entry_focus_out_callback),
gfs);
gtk_widget_show (gfs->entry);
/* this callback does the rest (pixmap creation etc.) */
gtk_signal_connect (GTK_OBJECT(gfs), "realize",
GTK_SIGNAL_FUNC(gimp_file_selection_realize), gfs);
}
GtkType
......@@ -166,7 +169,7 @@ gimp_file_selection_get_type (void)
return gfs_type;
}
GtkWidget*
GtkWidget *
gimp_file_selection_new (gchar *title,
gchar *filename,
gboolean dir_only,
......@@ -185,28 +188,25 @@ gimp_file_selection_new (gchar *title,
}
static void
gimp_file_selection_realize (GtkWidget *widget,
gpointer data)
gimp_file_selection_realize (GtkWidget *widget)
{
GimpFileSelection *gfs;
GtkStyle *style;
GtkWidget *parent;
gfs = GIMP_FILE_SELECTION (data);
gfs = GIMP_FILE_SELECTION (widget);
if (! gfs->check_valid)
return;
parent = GTK_WIDGET (gfs)->parent;
if (! GTK_WIDGET_REALIZED (parent))
return;
if (GTK_WIDGET_CLASS (parent_class)->realize)
(* GTK_WIDGET_CLASS (parent_class)->realize) (widget);
style = gtk_widget_get_style (parent);
style = gtk_widget_get_style (widget);
gfs->yes_pixmap = gdk_pixmap_create_from_xpm_d (parent->window,
gfs->yes_pixmap = gdk_pixmap_create_from_xpm_d (widget->window,
&gfs->yes_mask,
&style->bg[GTK_STATE_NORMAL],
yes_xpm);
gfs->no_pixmap = gdk_pixmap_create_from_xpm_d (parent->window,
gfs->no_pixmap = gdk_pixmap_create_from_xpm_d (widget->window,
&gfs->no_mask,
&style->bg[GTK_STATE_NORMAL],
no_xpm);
......@@ -218,7 +218,7 @@ gimp_file_selection_realize (GtkWidget *widget,
gtk_widget_show (gfs->file_exists);
}
gchar*
gchar *
gimp_file_selection_get_filename (GimpFileSelection *gfs)
{
g_return_val_if_fail (gfs != NULL, g_strdup (""));
......@@ -358,25 +358,25 @@ gimp_file_selection_browse_callback (GtkWidget *widget,
gtk_signal_connect
(GTK_OBJECT (GTK_FILE_SELECTION (gfs->file_selection)->ok_button),
"clicked",
(GtkSignalFunc)gimp_file_selection_filesel_ok_callback,
GTK_SIGNAL_FUNC (gimp_file_selection_filesel_ok_callback),
gfs);
gtk_signal_connect
(GTK_OBJECT (GTK_FILE_SELECTION (gfs->file_selection)->selection_entry),
"activate",
(GtkSignalFunc)gimp_file_selection_filesel_ok_callback,
GTK_SIGNAL_FUNC (gimp_file_selection_filesel_ok_callback),
gfs);
gtk_signal_connect
(GTK_OBJECT (GTK_FILE_SELECTION (gfs->file_selection)->cancel_button),
"clicked",
(GtkSignalFunc)gimp_file_selection_filesel_cancel_callback,
GTK_SIGNAL_FUNC (gimp_file_selection_filesel_cancel_callback),
gfs);
gtk_signal_connect
(GTK_OBJECT (gfs), "unmap",
(GtkSignalFunc)gimp_file_selection_filesel_cancel_callback,
GTK_SIGNAL_FUNC (gimp_file_selection_filesel_cancel_callback),
gfs);
gtk_signal_connect
(GTK_OBJECT (gfs->file_selection), "delete_event",
(GdkEventFunc)gimp_file_selection_filesel_delete_callback,
GTK_SIGNAL_FUNC (gimp_file_selection_filesel_delete_callback),
gfs);
}
......
......@@ -19,20 +19,20 @@
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#include <string.h>
#include "gimppatheditor.h"
#include "libgimp/gimpfileselection.h"
#include "libgimp/gimpintl.h"
#include <string.h>
#include "pixmaps/new.xpm"
#include "pixmaps/delete.xpm"
#include "pixmaps/raise.xpm"
#include "pixmaps/lower.xpm"
/* forward declaration */
static void gimp_path_editor_realize (GtkWidget *widget, gpointer data);
static void gimp_path_editor_realize (GtkWidget *widget);
static void gimp_path_editor_select_callback (GtkWidget *widget, gpointer data);
static void gimp_path_editor_deselect_callback (GtkWidget *widget,
gpointer data);
......@@ -41,14 +41,13 @@ static void gimp_path_editor_move_callback (GtkWidget *widget, gpointer data)
static void gimp_path_editor_filesel_callback (GtkWidget *widget, gpointer data);
static void gimp_path_editor_delete_callback (GtkWidget *widget, gpointer data);
static void gimp_path_editor_data_destroy_callback (gpointer *data);
/*
static void gimp_path_editor_check_path (GimpPathEditor *gpe,
GtkWidget *list_item);
*/
enum {
enum
{
PATH_CHANGED,
LAST_SIGNAL
};
......@@ -61,23 +60,27 @@ static void
gimp_path_editor_class_init (GimpPathEditorClass *class)
{
GtkObjectClass *object_class;
GtkWidgetClass *widget_class;
object_class = (GtkObjectClass*) class;
object_class = (GtkObjectClass *) class;
widget_class = (GtkWidgetClass *) class;
parent_class = gtk_type_class (gtk_vbox_get_type ());
gimp_path_editor_signals[PATH_CHANGED] =
gtk_signal_new ("path_changed",
GTK_RUN_FIRST,
object_class->type,
GTK_SIGNAL_OFFSET (GimpPathEditorClass,
path_changed),
gtk_signal_default_marshaller, GTK_TYPE_NONE, 0);
gtk_signal_new ("path_changed",
GTK_RUN_FIRST,
object_class->type,
GTK_SIGNAL_OFFSET (GimpPathEditorClass,
path_changed),
gtk_signal_default_marshaller, GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, gimp_path_editor_signals,
LAST_SIGNAL);
class->path_changed = NULL;
widget_class->realize = gimp_path_editor_realize;
}
static void
......@@ -85,8 +88,6 @@ gimp_path_editor_init (GimpPathEditor *gpe)
{
GtkWidget *button_box;
GtkWidget *scrolled_window;
GtkObject *hadjustment;
GtkObject *vadjustment;
gpe->file_selection = NULL;
gpe->selected_item = NULL;
......@@ -102,32 +103,35 @@ gimp_path_editor_init (GimpPathEditor *gpe)
gpe->new_button = gtk_button_new ();
gtk_box_pack_start (GTK_BOX (button_box), gpe->new_button, TRUE, TRUE, 0);
gtk_signal_connect (GTK_OBJECT(gpe->new_button), "clicked",
GTK_SIGNAL_FUNC(gimp_path_editor_new_callback), gpe);
gtk_signal_connect (GTK_OBJECT (gpe->new_button), "clicked",
GTK_SIGNAL_FUNC (gimp_path_editor_new_callback),
gpe);
gpe->up_button = gtk_button_new ();
gtk_widget_set_sensitive (gpe->up_button, FALSE);
gtk_box_pack_start (GTK_BOX (button_box), gpe->up_button, TRUE, TRUE, 0);
gtk_signal_connect (GTK_OBJECT(gpe->up_button), "clicked",
GTK_SIGNAL_FUNC(gimp_path_editor_move_callback), gpe);
gtk_signal_connect (GTK_OBJECT (gpe->up_button), "clicked",
GTK_SIGNAL_FUNC (gimp_path_editor_move_callback),
gpe);
gpe->down_button = gtk_button_new ();
gtk_widget_set_sensitive (gpe->down_button, FALSE);
gtk_box_pack_start (GTK_BOX (button_box), gpe->down_button, TRUE, TRUE, 0);
gtk_signal_connect (GTK_OBJECT(gpe->down_button), "clicked",
GTK_SIGNAL_FUNC(gimp_path_editor_move_callback), gpe);
gtk_signal_connect (GTK_OBJECT (gpe->down_button), "clicked",
GTK_SIGNAL_FUNC (gimp_path_editor_move_callback),
gpe);
gpe->delete_button = gtk_button_new ();
gtk_widget_set_sensitive (gpe->delete_button, FALSE);
gtk_box_pack_start (GTK_BOX (button_box), gpe->delete_button, TRUE, TRUE, 0);
gtk_signal_connect (GTK_OBJECT(gpe->delete_button), "clicked",
GTK_SIGNAL_FUNC(gimp_path_editor_delete_callback), gpe);
hadjustment