[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-core-devel
Subject: Re: New KAccel bug? [PATCH#2]
From: Ellis Whitehead <ellis () kde ! org>
Date: 2002-10-31 21:37:40
[Download RAW message or body]
On Wednesday 30 October 2002 23:22, Hasso Tepper wrote:
> Ellis Whitehead wrote:
> > Here's a patch for the problem. I'm afraid I don't have access to
> > a compilable cvs right now, so I can't test it. :( However, a
> > logic walk-through seems to indicate that it'll work. Please let
> > me know.
>
> Applying patch, recompiling kdecore, make install, restart kde ... no
> help. Problem is still there.
Ok, I found the problem.
m_code = XKeysymToKeycode( qt_xdisplay(), m_sym );
When a key symbol of zero is passed to XKeysymToKeycode(), it returns the
keycode for the 'E' key on some machines (setup-dependent, I think). So the
attached patch checks whether m_sym is zero before calling XKeysym...().
Please let me know if it works and I'll commit. :)
Cheers,
Ellis
["kkeynative_x11.cpp.diff" (text/x-diff)]
Index: kkeynative_x11.cpp
===================================================================
RCS file: /home/kde/kdelibs/kdecore/kkeynative_x11.cpp,v
retrieving revision 1.14
diff -u -3 -d -p -b -B -r1.14 kkeynative_x11.cpp
--- kkeynative_x11.cpp 2002/10/12 14:47:10 1.14
+++ kkeynative_x11.cpp 2002/10/31 21:30:54
@@ -94,7 +94,7 @@ bool KKeyNative::init( const KKey& key )
m_sym = key.sym();
uint modExtra = KKeyServer::Sym(m_sym).getModsRequired();
// Get the X modifier equivalent.
- if( !KKeyServer::modToModX( key.modFlags() | modExtra, m_mod ) ) {
+ if( !m_sym || !KKeyServer::modToModX( key.modFlags() | modExtra, m_mod ) ) {
m_sym = m_mod = 0;
m_code = 0;
return false;
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic