mirror of https://github.com/GNOME/gimp.git
renamed log domain TOOLS to TOOL_EVENTS and added domain TOOL_FOCUS.
2007-12-07 Michael Natterer <mitch@gimp.org> * app/gimp-log.[ch]: renamed log domain TOOLS to TOOL_EVENTS and added domain TOOL_FOCUS. * app/display/gimpdisplayshell-callbacks.c: s/TOOLS/TOOL_EVENTS/ * app/tools/gimptool.c: port focus debug output to GIMP_LOG(). svn path=/trunk/; revision=24287
This commit is contained in:
parent
58c2dd9bba
commit
efda62544d
|
@ -1,3 +1,12 @@
|
|||
2007-12-07 Michael Natterer <mitch@gimp.org>
|
||||
|
||||
* app/gimp-log.[ch]: renamed log domain TOOLS to TOOL_EVENTS and
|
||||
added domain TOOL_FOCUS.
|
||||
|
||||
* app/display/gimpdisplayshell-callbacks.c: s/TOOLS/TOOL_EVENTS/
|
||||
|
||||
* app/tools/gimptool.c: port focus debug output to GIMP_LOG().
|
||||
|
||||
2007-12-07 Michael Natterer <mitch@gimp.org>
|
||||
|
||||
* app/core/gimpselection.[ch]: added GErrors to
|
||||
|
|
|
@ -668,7 +668,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
|
|||
{
|
||||
GdkEventCrossing *cevent = (GdkEventCrossing *) event;
|
||||
|
||||
GIMP_LOG (TOOLS, "event (display %p): ENTER_NOTIFY", display);
|
||||
GIMP_LOG (TOOL_EVENTS, "event (display %p): ENTER_NOTIFY", display);
|
||||
|
||||
if (cevent->mode != GDK_CROSSING_NORMAL)
|
||||
return TRUE;
|
||||
|
@ -686,7 +686,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
|
|||
{
|
||||
GdkEventCrossing *cevent = (GdkEventCrossing *) event;
|
||||
|
||||
GIMP_LOG (TOOLS, "event (display %p): LEAVE_NOTIFY", display);
|
||||
GIMP_LOG (TOOL_EVENTS, "event (display %p): LEAVE_NOTIFY", display);
|
||||
|
||||
if (cevent->mode != GDK_CROSSING_NORMAL)
|
||||
return TRUE;
|
||||
|
@ -702,7 +702,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
|
|||
break;
|
||||
|
||||
case GDK_PROXIMITY_IN:
|
||||
GIMP_LOG (TOOLS, "event (display %p): PROXIMITY_IN", display);
|
||||
GIMP_LOG (TOOL_EVENTS, "event (display %p): PROXIMITY_IN", display);
|
||||
|
||||
tool_manager_oper_update_active (gimp,
|
||||
&image_coords, state,
|
||||
|
@ -711,7 +711,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
|
|||
break;
|
||||
|
||||
case GDK_PROXIMITY_OUT:
|
||||
GIMP_LOG (TOOLS, "event (display %p): PROXIMITY_OUT", display);
|
||||
GIMP_LOG (TOOL_EVENTS, "event (display %p): PROXIMITY_OUT", display);
|
||||
|
||||
shell->proximity = FALSE;
|
||||
gimp_display_shell_clear_cursor (shell);
|
||||
|
@ -728,7 +728,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
|
|||
|
||||
if (fevent->in)
|
||||
{
|
||||
GIMP_LOG (TOOLS, "event (display %p): FOCUS_IN", display);
|
||||
GIMP_LOG (TOOL_EVENTS, "event (display %p): FOCUS_IN", display);
|
||||
|
||||
GTK_WIDGET_SET_FLAGS (canvas, GTK_HAS_FOCUS);
|
||||
|
||||
|
@ -744,7 +744,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
|
|||
}
|
||||
else
|
||||
{
|
||||
GIMP_LOG (TOOLS, "event (display %p): FOCUS_OUT", display);
|
||||
GIMP_LOG (TOOL_EVENTS, "event (display %p): FOCUS_OUT", display);
|
||||
|
||||
GTK_WIDGET_UNSET_FLAGS (canvas, GTK_HAS_FOCUS);
|
||||
|
||||
|
@ -774,7 +774,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
|
|||
GdkEventButton *bevent = (GdkEventButton *) event;
|
||||
GdkEventMask event_mask;
|
||||
|
||||
GIMP_LOG (TOOLS, "event (display %p): BUTTON_PRESS (%d)",
|
||||
GIMP_LOG (TOOL_EVENTS, "event (display %p): BUTTON_PRESS (%d)",
|
||||
display, bevent->button);
|
||||
|
||||
if (! GTK_WIDGET_HAS_FOCUS (canvas))
|
||||
|
@ -921,7 +921,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
|
|||
{
|
||||
GdkEventButton *bevent = (GdkEventButton *) event;
|
||||
|
||||
GIMP_LOG (TOOLS, "event (display %p): BUTTON_RELEASE (%d)",
|
||||
GIMP_LOG (TOOL_EVENTS, "event (display %p): BUTTON_RELEASE (%d)",
|
||||
display, bevent->button);
|
||||
|
||||
gimp_display_shell_autoscroll_stop (shell);
|
||||
|
@ -988,7 +988,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
|
|||
GdkScrollDirection direction;
|
||||
GimpController *wheel;
|
||||
|
||||
GIMP_LOG (TOOLS, "event (display %p): SCROLL (%d)",
|
||||
GIMP_LOG (TOOL_EVENTS, "event (display %p): SCROLL (%d)",
|
||||
display, sevent->direction);
|
||||
|
||||
wheel = gimp_controllers_get_wheel (gimp);
|
||||
|
@ -1092,7 +1092,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
|
|||
GdkEventMotion *mevent = (GdkEventMotion *) event;
|
||||
GdkEvent *compressed_motion = NULL;
|
||||
|
||||
GIMP_LOG (TOOLS, "event (display %p): MOTION_NOTIFY", display);
|
||||
GIMP_LOG (TOOL_EVENTS, "event (display %p): MOTION_NOTIFY", display);
|
||||
|
||||
if (gimp->busy)
|
||||
return TRUE;
|
||||
|
@ -1256,7 +1256,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
|
|||
{
|
||||
GdkEventKey *kevent = (GdkEventKey *) event;
|
||||
|
||||
GIMP_LOG (TOOLS, "event (display %p): KEY_PRESS (%d, %s)",
|
||||
GIMP_LOG (TOOL_EVENTS, "event (display %p): KEY_PRESS (%d, %s)",
|
||||
display, kevent->keyval,
|
||||
gdk_keyval_name (kevent->keyval) ?
|
||||
gdk_keyval_name (kevent->keyval) : "<none>");
|
||||
|
@ -1371,7 +1371,7 @@ gimp_display_shell_canvas_tool_events (GtkWidget *canvas,
|
|||
{
|
||||
GdkEventKey *kevent = (GdkEventKey *) event;
|
||||
|
||||
GIMP_LOG (TOOLS, "event (display %p): KEY_RELEASE (%d, %s)",
|
||||
GIMP_LOG (TOOL_EVENTS, "event (display %p): KEY_RELEASE (%d, %s)",
|
||||
display, kevent->keyval,
|
||||
gdk_keyval_name (kevent->keyval) ?
|
||||
gdk_keyval_name (kevent->keyval) : "<none>");
|
||||
|
|
|
@ -35,7 +35,8 @@ gimp_log_init (void)
|
|||
{
|
||||
const GDebugKey log_keys[] =
|
||||
{
|
||||
{ "tools", GIMP_LOG_TOOLS },
|
||||
{ "tool-events", GIMP_LOG_TOOL_EVENTS },
|
||||
{ "tool-focus", GIMP_LOG_TOOL_FOCUS },
|
||||
{ "dnd", GIMP_LOG_DND },
|
||||
{ "help", GIMP_LOG_HELP },
|
||||
{ "dialog-factory", GIMP_LOG_DIALOG_FACTORY },
|
||||
|
|
|
@ -22,12 +22,13 @@
|
|||
|
||||
typedef enum
|
||||
{
|
||||
GIMP_LOG_TOOLS = 1 << 0,
|
||||
GIMP_LOG_DND = 1 << 1,
|
||||
GIMP_LOG_HELP = 1 << 2,
|
||||
GIMP_LOG_DIALOG_FACTORY = 1 << 3,
|
||||
GIMP_LOG_SAVE_DIALOG = 1 << 4,
|
||||
GIMP_LOG_IMAGE_SCALE = 1 << 5
|
||||
GIMP_LOG_TOOL_EVENTS = 1 << 0,
|
||||
GIMP_LOG_TOOL_FOCUS = 1 << 1,
|
||||
GIMP_LOG_DND = 1 << 2,
|
||||
GIMP_LOG_HELP = 1 << 3,
|
||||
GIMP_LOG_DIALOG_FACTORY = 1 << 4,
|
||||
GIMP_LOG_SAVE_DIALOG = 1 << 5,
|
||||
GIMP_LOG_IMAGE_SCALE = 1 << 6
|
||||
} GimpLogFlags;
|
||||
|
||||
|
||||
|
|
|
@ -37,6 +37,8 @@
|
|||
#include "gimptool.h"
|
||||
#include "gimptoolcontrol.h"
|
||||
|
||||
#include "gimp-log.h"
|
||||
|
||||
|
||||
enum
|
||||
{
|
||||
|
@ -624,10 +626,8 @@ gimp_tool_set_focus_display (GimpTool *tool,
|
|||
g_return_if_fail (GIMP_IS_TOOL (tool));
|
||||
g_return_if_fail (display == NULL || GIMP_IS_DISPLAY (display));
|
||||
|
||||
#ifdef DEBUG_FOCUS
|
||||
g_printerr ("%s: tool: %p display: %p focus_display: %p\n",
|
||||
G_STRFUNC, tool, display, tool->focus_display);
|
||||
#endif
|
||||
GIMP_LOG (TOOL_FOCUS, "tool: %p focus_display: %p tool->focus_display: %p",
|
||||
tool, display, tool->focus_display);
|
||||
|
||||
if (display != tool->focus_display)
|
||||
{
|
||||
|
@ -678,10 +678,8 @@ gimp_tool_set_modifier_state (GimpTool *tool,
|
|||
g_return_if_fail (GIMP_IS_TOOL (tool));
|
||||
g_return_if_fail (GIMP_IS_DISPLAY (display));
|
||||
|
||||
#ifdef DEBUG_FOCUS
|
||||
g_printerr ("%s: tool: %p display: %p focus_display: %p\n",
|
||||
G_STRFUNC, tool, display, tool->focus_display);
|
||||
#endif
|
||||
GIMP_LOG (TOOL_FOCUS, "tool: %p display: %p tool->focus_display: %p",
|
||||
tool, display, tool->focus_display);
|
||||
|
||||
g_return_if_fail (display == tool->focus_display);
|
||||
|
||||
|
@ -732,6 +730,9 @@ gimp_tool_set_active_modifier_state (GimpTool *tool,
|
|||
g_return_if_fail (GIMP_IS_TOOL (tool));
|
||||
g_return_if_fail (GIMP_IS_DISPLAY (display));
|
||||
|
||||
GIMP_LOG (TOOL_FOCUS, "tool: %p display: %p tool->focus_display: %p",
|
||||
tool, display, tool->focus_display);
|
||||
|
||||
g_return_if_fail (display == tool->focus_display);
|
||||
|
||||
if ((tool->active_modifier_state & GDK_SHIFT_MASK) !=
|
||||
|
|
Loading…
Reference in New Issue