]> git.lyx.org Git - lyx.git/commitdiff
don't crash when you press Alt Gr etc. :)
authorJohn Levon <levon@movementarian.org>
Mon, 22 Jul 2002 22:07:16 +0000 (22:07 +0000)
committerJohn Levon <levon@movementarian.org>
Mon, 22 Jul 2002 22:07:16 +0000 (22:07 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@4755 a592a061-630c-0410-9148-cb99ea01b6c8

src/frontends/qt2/ChangeLog
src/frontends/qt2/QLyXKeySym.C

index ec0385f89ae7d1f2ea84460c1b1a2a36a625fc38..9ce4cb8431e81c1d0e6c186f4733bfadc9ddd29f 100644 (file)
@@ -1,3 +1,8 @@
+2002-07-22  John Levon  <moz@compsoc.man.ac.uk>
+
+       * QLyXKeySym.C: return 0 when text_ is empty
+         for getISOEncoded() 
+
 2002-07-22  John Levon  <moz@compsoc.man.ac.uk>
 
        * QCommandBuffer.C: probably compile fix
index aeeccc9dcb49a41103543fd42426714a3c4a1161..c42dc3febede968b239cd923dccf497e18a5af1b 100644 (file)
@@ -56,6 +56,8 @@ string QLyXKeySym::getSymbolName() const
  
 char QLyXKeySym::getISOEncoded() const
 {
+       if (!text_.length()) 
+               return 0;
        // FIXME
        return text_.latin1()[0];
 }