Fix some tomboy warnings
authorIra W. Snyder <devel@irasnyder.com>
Fri, 25 Jan 2008 08:46:28 +0000 (00:46 -0800)
committerIra W. Snyder <devel@irasnyder.com>
Fri, 25 Jan 2008 08:46:28 +0000 (00:46 -0800)
There were some warnings because of the use of EggVirtualModifierType,
but the type can be changed to the GdkModifierType. A close examination
of the code shows that they are already equivalent, anyway.

Some of the code that was in the eggaccelerators.c has been moved into
GTK+. Some research shows that libegg was a staging library to test
experimental code before moving it into GTK+. This explains why lots of
the eggaccelerators.c code is duplicated exactly in GTK+.

eggaccelerators.c
eggaccelerators.h
tomboykeybinder.c

index be39bdc..94b52ea 100644 (file)
@@ -464,7 +464,7 @@ egg_virtual_accelerator_name (guint                  accelerator_key,
 
 void
 egg_keymap_resolve_virtual_modifiers (GdkKeymap              *keymap,
-                                      EggVirtualModifierType  virtual_mods,
+                                      GdkModifierType         virtual_mods,
                                       GdkModifierType        *concrete_mods)
 {
   GdkModifierType concrete;
index 8b624f8..c6fc0c6 100644 (file)
@@ -74,7 +74,7 @@ gboolean egg_accelerator_parse_virtual        (const gchar            *accelerat
                                                EggVirtualModifierType *accelerator_mods);
 #endif
 void     egg_keymap_resolve_virtual_modifiers (GdkKeymap              *keymap,
-                                               EggVirtualModifierType  virtual_mods,
+                                               GdkModifierType         virtual_mods,
                                                GdkModifierType        *concrete_mods);
 #if 0
 void     egg_keymap_virtualize_modifiers      (GdkKeymap              *keymap,
index cea1725..d88daa3 100644 (file)
@@ -88,7 +88,7 @@ do_grab_key (Binding *binding)
        GdkKeymap *keymap = gdk_keymap_get_default ();
        GdkWindow *rootwin = gdk_get_default_root_window ();
 
-       EggVirtualModifierType virtual_mods = 0;
+       GdkModifierType virtual_mods = 0;
        guint keysym = 0;
 
        if (keymap == NULL || rootwin == NULL)
@@ -98,12 +98,6 @@ do_grab_key (Binding *binding)
 
        if (keysym == 0 && virtual_mods == 0)
                return FALSE;
-#if 0
-       if (!egg_accelerator_parse_virtual (binding->keystring, 
-                                           &keysym, 
-                                           &virtual_mods))
-               return FALSE;
-#endif
 
        TRACE (g_print ("Got accel %d, %d\n", keysym, virtual_mods));