[gimp] app: some forgotten s/GDK_foo/GDK_KEY_foo/



commit 1cdaa2846feaa724c74261a997d3d9d8ad2e816e
Author: Michael Natterer <mitch gimp org>
Date:   Tue Mar 29 18:53:02 2011 +0200

    app: some forgotten s/GDK_foo/GDK_KEY_foo/

 app/tests/test-save-and-export.c |    1 -
 app/tests/test-tools.c           |    2 +-
 app/tests/test-ui.c              |    4 ++--
 app/widgets/gimpcurveview.c      |   10 +++++-----
 app/widgets/widgets-types.h      |    2 ++
 5 files changed, 10 insertions(+), 9 deletions(-)
---
diff --git a/app/tests/test-save-and-export.c b/app/tests/test-save-and-export.c
index 4cd90d7..821e872 100644
--- a/app/tests/test-save-and-export.c
+++ b/app/tests/test-save-and-export.c
@@ -21,7 +21,6 @@
 #include <gegl.h>
 #include <glib/gstdio.h>
 #include <gtk/gtk.h>
-#include <gdk/gdkkeysyms.h>
 
 #include "libgimpbase/gimpbase.h"
 #include "libgimpmath/gimpmath.h"
diff --git a/app/tests/test-tools.c b/app/tests/test-tools.c
index 54de1c7..5a8570c 100644
--- a/app/tests/test-tools.c
+++ b/app/tests/test-tools.c
@@ -410,7 +410,7 @@ crop_tool_can_crop (GimpTestFixture *fixture,
                                                   0 /*modifiers*/);
 
   /* Crop */
-  gimp_test_utils_synthesize_key_event (GTK_WIDGET (shell), GDK_Return);
+  gimp_test_utils_synthesize_key_event (GTK_WIDGET (shell), GDK_KEY_Return);
   gimp_test_run_mainloop_until_idle ();
 
   /* Make sure the new image has the expected size */
diff --git a/app/tests/test-ui.c b/app/tests/test-ui.c
index 49f4e1c..7a2c908 100644
--- a/app/tests/test-ui.c
+++ b/app/tests/test-ui.c
@@ -285,7 +285,7 @@ keyboard_zoom_focus (GimpTestFixture *fixture,
   factor_before_zoom = gimp_zoom_model_get_factor (shell->zoom);
 
   /* Do the zoom */
-  gimp_test_utils_synthesize_key_event (GTK_WIDGET (window), GDK_plus);
+  gimp_test_utils_synthesize_key_event (GTK_WIDGET (window), GDK_KEY_plus);
   gimp_test_run_mainloop_until_idle ();
 
   /* Make sure the zoom focus point remained fixed */
@@ -299,7 +299,7 @@ keyboard_zoom_focus (GimpTestFixture *fixture,
   /* First of all make sure a zoom happend at all. If this assert
    * fails, it means that the zoom didn't happen. Possible causes:
    *
-   *  * gdk_test_simulate_key() failed to map 'GDK_plus' to the proper
+   *  * gdk_test_simulate_key() failed to map 'GDK_KEY_plus' to the proper
    *    'plus' X keysym, probably because it is mapped to a keycode
    *    with modifiers like 'shift'. Run "xmodmap -pk | grep plus" to
    *    find out. Make sure 'plus' is the first keysym for the given
diff --git a/app/widgets/gimpcurveview.c b/app/widgets/gimpcurveview.c
index ab50c05..1762fef 100644
--- a/app/widgets/gimpcurveview.c
+++ b/app/widgets/gimpcurveview.c
@@ -946,7 +946,7 @@ gimp_curve_view_key_press (GtkWidget   *widget,
 
       switch (kevent->keyval)
         {
-        case GDK_Left:
+        case GDK_KEY_Left:
           for (i = i - 1; i >= 0 && ! handled; i--)
             {
               gimp_curve_get_point (curve, i, &x, NULL);
@@ -960,7 +960,7 @@ gimp_curve_view_key_press (GtkWidget   *widget,
             }
           break;
 
-        case GDK_Right:
+        case GDK_KEY_Right:
           for (i = i + 1; i < curve->n_points && ! handled; i++)
             {
               gimp_curve_get_point (curve, i, &x, NULL);
@@ -974,7 +974,7 @@ gimp_curve_view_key_press (GtkWidget   *widget,
             }
           break;
 
-        case GDK_Up:
+        case GDK_KEY_Up:
           if (y < 1.0)
             {
               y = y + (kevent->state & GDK_SHIFT_MASK ?
@@ -986,7 +986,7 @@ gimp_curve_view_key_press (GtkWidget   *widget,
             }
           break;
 
-        case GDK_Down:
+        case GDK_KEY_Down:
           if (y > 0)
             {
               y = y - (kevent->state & GDK_SHIFT_MASK ?
@@ -998,7 +998,7 @@ gimp_curve_view_key_press (GtkWidget   *widget,
             }
           break;
 
-        case GDK_Delete:
+        case GDK_KEY_Delete:
           gimp_curve_delete_point (curve, i);
           break;
 
diff --git a/app/widgets/widgets-types.h b/app/widgets/widgets-types.h
index 001e99f..6f6ae34 100644
--- a/app/widgets/widgets-types.h
+++ b/app/widgets/widgets-types.h
@@ -58,6 +58,8 @@
 #define GDK_KEY_v GDK_v
 #define GDK_KEY_plus GDK_plus
 #define GDK_KEY_minus GDK_minus
+#define GDK_KEY_Delete GDK_Delete
+#define GDK_KEY_plus GDK_plus
 #endif
 
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]