gnome-settings-daemon r240 - in trunk: . plugins/keybindings plugins/media-keys



Author: jensg
Date: Sat Mar 29 13:27:20 2008
New Revision: 240
URL: http://svn.gnome.org/viewvc/gnome-settings-daemon?rev=240&view=rev

Log:
2008-03-29  Jens Granseuer  <jensgr gmx net>

	* plugins/keybindings/eggaccelerators.c:
	(egg_accelerator_parse_virtual):
	* plugins/media-keys/eggaccelerators.c:
	(egg_accelerator_parse_virtual): readd a chunk that got lost in the
	last commit. *sigh*. Why do we have several differing copies of those
	files?


Modified:
   trunk/ChangeLog
   trunk/plugins/keybindings/eggaccelerators.c
   trunk/plugins/media-keys/eggaccelerators.c

Modified: trunk/plugins/keybindings/eggaccelerators.c
==============================================================================
--- trunk/plugins/keybindings/eggaccelerators.c	(original)
+++ trunk/plugins/keybindings/eggaccelerators.c	Sat Mar 29 13:27:20 2008
@@ -345,7 +345,7 @@
 		    {
 		      bad_keyval = TRUE;
 		    }
-		  else
+		  else if (keycode != NULL)
 		    {
 		      *keycode = tmp_keycode;
 		      /* 0x00 is an invalid keycode too. */
@@ -354,6 +354,12 @@
 		    }
 		}
 	    }
+	  else if (keycode != NULL)
+	    {
+	      *keycode = XKeysymToKeycode (GDK_DISPLAY(), keyval);
+	      if (*keycode == 0)
+	 	bad_keyval = TRUE;
+	    }
 
           accelerator += len;
           len -= len;

Modified: trunk/plugins/media-keys/eggaccelerators.c
==============================================================================
--- trunk/plugins/media-keys/eggaccelerators.c	(original)
+++ trunk/plugins/media-keys/eggaccelerators.c	Sat Mar 29 13:27:20 2008
@@ -345,7 +345,7 @@
 		    {
 		      bad_keyval = TRUE;
 		    }
-		  else
+		  else if (keycode != NULL)
 		    {
 		      *keycode = tmp_keycode;
 		      /* 0x00 is an invalid keycode too. */
@@ -354,6 +354,12 @@
 		    }
 		}
 	    }
+	  else if (keycode != NULL)
+	    {
+	      *keycode = XKeysymToKeycode (GDK_DISPLAY(), keyval);
+	      if (*keycode == 0)
+	 	bad_keyval = TRUE;
+	    }
 
           accelerator += len;
           len -= len;



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