Commit 78616838 authored by Julien Moutte's avatar Julien Moutte
Browse files

sys/: Looking at Xorg code i can't figure out if that XKeysymToString function...

sys/: Looking at Xorg code i can't figure out if that XKeysymToString function is thread sensible or not. Lock it jus...

Original commit message from CVS:
2007-01-22  Julien MOUTTE  <julien@moutte.net>

* sys/ximage/ximagesink.c: (gst_ximagesink_handle_xevents):
* sys/xvimage/xvimagesink.c: (gst_xvimagesink_handle_xevents):
Looking at Xorg code i can't figure out if that XKeysymToString
function is thread sensible or not. Lock it just in case as
recommended by Radek Doulik <rodo at ximian dot com>.
parent 34af6e72
2007-01-22 Julien MOUTTE <julien@moutte.net>
* sys/ximage/ximagesink.c: (gst_ximagesink_handle_xevents):
* sys/xvimage/xvimagesink.c: (gst_xvimagesink_handle_xevents):
Looking at Xorg code i can't figure out if that XKeysymToString
function is thread sensible or not. Lock it just in case as
recommended by Radek Doulik <rodo at ximian dot com>.
2007-01-22 Julien MOUTTE <julien@moutte.net>
 
* sys/ximage/ximagesink.c: (gst_ximagesink_handle_xevents):
......@@ -967,9 +967,11 @@ gst_ximagesink_handle_xevents (GstXImageSink * ximagesink)
e.xkey.keycode, 0);
g_mutex_unlock (ximagesink->x_lock);
if (keysym != NoSymbol) {
g_mutex_lock (ximagesink->x_lock);
gst_navigation_send_key_event (GST_NAVIGATION (ximagesink),
e.type == KeyPress ?
"key-press" : "key-release", XKeysymToString (keysym));
g_mutex_unlock (ximagesink->x_lock);
} else {
gst_navigation_send_key_event (GST_NAVIGATION (ximagesink),
e.type == KeyPress ? "key-press" : "key-release", "unknown");
......
......@@ -1092,9 +1092,11 @@ gst_xvimagesink_handle_xevents (GstXvImageSink * xvimagesink)
e.xkey.keycode, 0);
g_mutex_unlock (xvimagesink->x_lock);
if (keysym != NoSymbol) {
g_mutex_lock (xvimagesink->x_lock);
gst_navigation_send_key_event (GST_NAVIGATION (xvimagesink),
e.type == KeyPress ?
"key-press" : "key-release", XKeysymToString (keysym));
g_mutex_unlock (xvimagesink->x_lock);
} else {
gst_navigation_send_key_event (GST_NAVIGATION (xvimagesink),
e.type == KeyPress ? "key-press" : "key-release", "unknown");
......
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