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

app/gdisplay.c app/gimage.c. #include "tools/tool.h"

2001-02-28  Michael Natterer  <mitch@gimp.org>

	* app/gdisplay.c
	* app/gimage.c. #include "tools/tool.h"

	* app/tools/edit_selection.[ch]: the arrow_key function is not
	a method of edit_selection but of any tool that needs it.

	* app/tools/gimppaintbrushtool.c: removed variables.

	* app/tools/move.c: use the arrow_key function.

	* app/tools/tool_manager.h: removed the include of "tool.h"
parent 904d8e2c
2001-02-28 Michael Natterer <mitch@gimp.org>
* app/gdisplay.c
* app/gimage.c. #include "tools/tool.h"
* app/tools/edit_selection.[ch]: the arrow_key function is not
a method of edit_selection but of any tool that needs it.
* app/tools/gimppaintbrushtool.c: removed variables.
* app/tools/move.c: use the arrow_key function.
* app/tools/tool_manager.h: removed the include of "tool.h"
2001-02-28 Michael Natterer <mitch@gimp.org>
* app/tools/Makefile.am
......@@ -45,7 +59,7 @@
* app/tools/gimptoolinfo.[ch]: added a "tool_context" boolean to
the constructor and create a private context for the tool
initialized with global_paint_options's values.
initialized with global_paint_options' values.
* app/tools/tool_manager.[ch]: changed tool_manager_register_tool()
accordingly.
......
......@@ -27,6 +27,9 @@
#include "apptypes.h"
#include "tools/tool.h"
#include "tools/tool_manager.h"
#include "appenv.h"
#include "colormaps.h"
#include "cursorutil.h"
......@@ -61,8 +64,6 @@
#include "gdisplay_color.h"
#endif /* DISPLAY_FILTERS */
#include "tools/tool_manager.h"
#include "libgimp/gimpintl.h"
......
......@@ -27,6 +27,9 @@
#include "apptypes.h"
#include "tools/tool.h"
#include "tools/tool_manager.h"
#include "appenv.h"
#include "colormaps.h"
#include "cursorutil.h"
......@@ -61,8 +64,6 @@
#include "gdisplay_color.h"
#endif /* DISPLAY_FILTERS */
#include "tools/tool_manager.h"
#include "libgimp/gimpintl.h"
......
......@@ -27,6 +27,9 @@
#include "apptypes.h"
#include "tools/tool.h"
#include "tools/tool_manager.h"
#include "appenv.h"
#include "colormaps.h"
#include "cursorutil.h"
......@@ -61,8 +64,6 @@
#include "gdisplay_color.h"
#endif /* DISPLAY_FILTERS */
#include "tools/tool_manager.h"
#include "libgimp/gimpintl.h"
......
......@@ -22,6 +22,7 @@
#include "apptypes.h"
#include "tools/tool.h"
#include "tools/tool_manager.h"
#include "context_manager.h"
......
......@@ -73,14 +73,10 @@ struct _PaintbrushOptions
static PaintbrushOptions * paintbrush_options = NULL;
/* local variables */
static gdouble non_gui_fade_out;
static gdouble non_gui_gradient_length;
static gint non_gui_gradient_type;
static gdouble non_gui_incremental;
static GimpUnit non_gui_fade_unit;
static GimpUnit non_gui_gradient_unit;
static GimpPaintToolClass *parent_class;
static GimpPaintToolClass *parent_class = NULL;
/* forward function declarations */
static void gimp_paintbrush_tool_motion (GimpPaintTool *,
......
......@@ -110,7 +110,7 @@ static void gimp_edit_selection_tool_control (GimpTool *tool,
static void gimp_edit_selection_tool_cursor_update (GimpTool *tool,
GdkEventMotion *mevent,
GDisplay *gdisp);
static void gimp_edit_selection_tool_arrow_key (GimpTool *tool,
void gimp_edit_selection_tool_arrow_key (GimpTool *tool,
GdkEventKey *kevent,
GDisplay *gdisp);
......@@ -164,7 +164,6 @@ gimp_edit_selection_tool_class_init (GimpEditSelectionToolClass *klass)
tool_class->button_release = gimp_edit_selection_tool_button_release;
tool_class->motion = gimp_edit_selection_tool_motion;
tool_class->cursor_update = gimp_edit_selection_tool_cursor_update;
tool_class->arrow_key = gimp_edit_selection_tool_arrow_key;
draw_class->draw = gimp_edit_selection_tool_draw;
}
......@@ -878,19 +877,16 @@ process_event_queue_keys (GdkEventKey *kevent,
#undef FILTER_MAX_KEYS
}
static void
void
gimp_edit_selection_tool_arrow_key (GimpTool *tool,
GdkEventKey *kevent,
GDisplay *gdisp)
{
GimpEditSelectionTool *edit_select;
gint inc_x, inc_y, mask_inc_x, mask_inc_y;
GimpLayer *layer;
GimpLayer *floating_layer;
GList *layer_list;
EditType edit_type;
edit_select = GIMP_EDIT_SELECTION_TOOL (tool);
gint inc_x, inc_y, mask_inc_x, mask_inc_y;
GimpLayer *layer;
GimpLayer *floating_layer;
GList *layer_list;
EditType edit_type;
layer = NULL;
......
......@@ -35,4 +35,9 @@ void init_edit_selection (GimpTool *tool,
EditType edit_type);
void gimp_edit_selection_tool_arrow_key (GimpTool *tool,
GdkEventKey *kevent,
GDisplay *gdisp);
#endif /* __GIMP_EDIT_SELECTION_TOOL_H__ */
......@@ -110,7 +110,7 @@ static void gimp_edit_selection_tool_control (GimpTool *tool,
static void gimp_edit_selection_tool_cursor_update (GimpTool *tool,
GdkEventMotion *mevent,
GDisplay *gdisp);
static void gimp_edit_selection_tool_arrow_key (GimpTool *tool,
void gimp_edit_selection_tool_arrow_key (GimpTool *tool,
GdkEventKey *kevent,
GDisplay *gdisp);
......@@ -164,7 +164,6 @@ gimp_edit_selection_tool_class_init (GimpEditSelectionToolClass *klass)
tool_class->button_release = gimp_edit_selection_tool_button_release;
tool_class->motion = gimp_edit_selection_tool_motion;
tool_class->cursor_update = gimp_edit_selection_tool_cursor_update;
tool_class->arrow_key = gimp_edit_selection_tool_arrow_key;
draw_class->draw = gimp_edit_selection_tool_draw;
}
......@@ -878,19 +877,16 @@ process_event_queue_keys (GdkEventKey *kevent,
#undef FILTER_MAX_KEYS
}
static void
void
gimp_edit_selection_tool_arrow_key (GimpTool *tool,
GdkEventKey *kevent,
GDisplay *gdisp)
{
GimpEditSelectionTool *edit_select;
gint inc_x, inc_y, mask_inc_x, mask_inc_y;
GimpLayer *layer;
GimpLayer *floating_layer;
GList *layer_list;
EditType edit_type;
edit_select = GIMP_EDIT_SELECTION_TOOL (tool);
gint inc_x, inc_y, mask_inc_x, mask_inc_y;
GimpLayer *layer;
GimpLayer *floating_layer;
GList *layer_list;
EditType edit_type;
layer = NULL;
......
......@@ -35,4 +35,9 @@ void init_edit_selection (GimpTool *tool,
EditType edit_type);
void gimp_edit_selection_tool_arrow_key (GimpTool *tool,
GdkEventKey *kevent,
GDisplay *gdisp);
#endif /* __GIMP_EDIT_SELECTION_TOOL_H__ */
......@@ -134,6 +134,7 @@ gimp_move_tool_class_init (GimpMoveToolClass *klass)
tool_class->button_release = move_tool_button_release;
tool_class->motion = move_tool_motion;
tool_class->cursor_update = move_tool_cursor_update;
tool_class->arrow_key = gimp_edit_selection_tool_arrow_key;
}
static void
......
......@@ -73,14 +73,10 @@ struct _PaintbrushOptions
static PaintbrushOptions * paintbrush_options = NULL;
/* local variables */
static gdouble non_gui_fade_out;
static gdouble non_gui_gradient_length;
static gint non_gui_gradient_type;
static gdouble non_gui_incremental;
static GimpUnit non_gui_fade_unit;
static GimpUnit non_gui_gradient_unit;
static GimpPaintToolClass *parent_class;
static GimpPaintToolClass *parent_class = NULL;
/* forward function declarations */
static void gimp_paintbrush_tool_motion (GimpPaintTool *,
......
......@@ -134,6 +134,7 @@ gimp_move_tool_class_init (GimpMoveToolClass *klass)
tool_class->button_release = move_tool_button_release;
tool_class->motion = move_tool_motion;
tool_class->cursor_update = move_tool_cursor_update;
tool_class->arrow_key = gimp_edit_selection_tool_arrow_key;
}
static void
......
......@@ -20,24 +20,27 @@
#define __TOOL_MANAGER_H__
#include "tool.h" /* EEEEEEEEEEK */
/* Global Data Structures */
extern GimpTool *active_tool;
extern GimpContainer *global_tool_info_list;
/* Function declarations */
void tool_manager_select_tool (GimpTool *tool);
void tool_manager_select_tool (GimpTool *tool);
void tool_manager_push_tool (GimpTool *tool);
void tool_manager_pop_tool (void);
void tool_manager_push_tool (GimpTool *tool);
void tool_manager_pop_tool (void);
void tool_manager_initialize_tool (GimpTool *tool,
GDisplay *gdisp);
void tool_manager_initialize_tool (GimpTool *tool,
GDisplay *gdisp);
void tool_manager_control_active (ToolAction action,
GDisplay *gdisp);
void tool_manager_control_active (ToolAction action,
GDisplay *gdisp);
const gchar * tool_manager_active_get_PDB_string (void);
const gchar * tool_manager_active_get_help_data (void);
void tool_manager_register (GimpToolClass *tool_type
/*, ToolOptions *tool_options*/);
void tool_manager_init (void);
......@@ -56,21 +59,12 @@ void tool_manager_register_tool (GtkType tool_type,
void tool_manager_register_tool_options (GtkType tool_type,
ToolOptions *tool_options);
GimpToolInfo * tool_manager_get_info_by_type (GtkType tool_type);
GimpToolInfo * tool_manager_get_info_by_tool (GimpTool *tool);
GimpToolInfo * tool_manager_get_info_by_type (GtkType tool_type);
GimpToolInfo * tool_manager_get_info_by_tool (GimpTool *tool);
const gchar * tool_manager_active_get_PDB_string (void);
const gchar * tool_manager_active_get_help_data (void);
void tool_manager_help_func (const gchar *help_data);
/* Global Data Structures */
extern GimpTool *active_tool;
extern GimpContainer *global_tool_info_list;
#endif /* __TOOL_MANAGER_H__ */
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment