From b25d19435a9d08f91531adc9e5f04b54516319a3 Mon Sep 17 00:00:00 2001 From: Jean-Marc Lasgouttes Date: Thu, 3 Jun 2010 07:26:19 +0000 Subject: [PATCH] fix compilation on F13 and binutils/gold by rewriting specialized X11 code git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34588 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/frontends/qt4/GuiWorkArea.cpp | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/src/frontends/qt4/GuiWorkArea.cpp b/src/frontends/qt4/GuiWorkArea.cpp index 8a9346b6a8..9d9d82abf8 100644 --- a/src/frontends/qt4/GuiWorkArea.cpp +++ b/src/frontends/qt4/GuiWorkArea.cpp @@ -72,11 +72,6 @@ #include -#ifdef Q_WS_X11 -#include -extern "C" int XEventsQueued(Display *display, int mode); -#endif - #ifdef Q_WS_WIN int const CursorWidth = 2; #else @@ -911,11 +906,10 @@ void GuiWorkArea::keyPressEvent(QKeyEvent * ev) // do nothing if there are other events // (the auto repeated events come too fast) - // \todo FIXME: remove hard coded Qt keys, process the key binding + // it looks like this is only needed on X11 #ifdef Q_WS_X11 - if (XEventsQueued(QX11Info::display(), 0) > 1 && ev->isAutoRepeat() - && (Qt::Key_PageDown || Qt::Key_PageUp)) { - LYXERR(Debug::KEY, "system is busy: scroll key event ignored"); + if (qApp->hasPendingEvents() && ev->isAutoRepeat()) { + LYXERR(Debug::KEY, "system is busy: keyPress event ignored"); ev->ignore(); return; } -- 2.39.2