winex11.drv: Hack to work around an Xlib bug when XInitThreads is used.

This commit is contained in:
Alexandre Julliard 2006-10-19 13:36:33 +02:00
parent 4c4d4386ed
commit 8532cc5654
1 changed files with 8 additions and 1 deletions

View File

@ -514,7 +514,14 @@ struct x11drv_thread_data *x11drv_init_thread_data(void)
if (use_xkb)
{
use_xkb = XkbUseExtension( data->display, NULL, NULL );
if (use_xkb) XkbSetDetectableAutoRepeat( data->display, True, NULL );
if (use_xkb)
{
/* Hack: dummy call to XkbKeysymToModifiers to force initialisation of Xkb internals */
/* This works around an Xlib bug where it tries to get the display lock */
/* twice during XFilterEvents if Xkb hasn't been initialised yet. */
XkbKeysymToModifiers( data->display, 'A' );
XkbSetDetectableAutoRepeat( data->display, True, NULL );
}
}
#endif