~ubuntu-branches/ubuntu/lucid/kdebase/lucid

« back to all changes in this revision

Viewing changes to debian/patches/kubuntu_72_kxkb_xmodmap.diff

  • Committer: Bazaar Package Importer
  • Author(s): Jonathan Riddell
  • Date: 2008-05-27 12:09:48 UTC
  • mfrom: (1.1.13 upstream)
  • Revision ID: james.westby@ubuntu.com-20080527120948-dottsyd5rcwhzd36
Tags: 4:4.0.80-1ubuntu1
* Merge with Debian
 - remove 97_fix_target_link_libraries.diff
 - Add replaces/conflicts on -kde4 packages

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
--- kdebase-3.5.5a.dfsg.1/kxkb/extension.cpp-orig       2007-01-05 12:37:35.000000000 +0000
2
 
+++ kdebase-3.5.5a.dfsg.1/kxkb/extension.cpp    2007-01-05 12:37:54.000000000 +0000
3
 
@@ -4,6 +4,7 @@
4
 
 #include <qstring.h>
5
 
 #include <qmap.h>
6
 
 #include <qfile.h>
7
 
+#include <qdir.h>
8
 
 
9
 
 #include <kdebug.h>
10
 
 #include <kstandarddirs.h>
11
 
@@ -176,12 +177,18 @@
12
 
     if( !fullVariant.isNull() && !fullVariant.isEmpty() )
13
 
         p << "-variant" << fullVariant;
14
 
 
15
 
-    if (p.start(KProcess::Block) && p.normalExit() && (p.exitStatus() == 0)) {
16
 
-               return true; //setGroup( group );
17
 
-    }
18
 
-    else {
19
 
-        return false;
20
 
-    }
21
 
+    p.start(KProcess::Block); 
22
 
+
23
 
+    // reload ubuntu hotkey-setup keycode -> keysym maps
24
 
+    KProcess pXmodmap;
25
 
+    pXmodmap << "/usr/bin/xmodmap" << "/usr/share/apps/kxkb/ubuntu.xmodmap";
26
 
+    pXmodmap.start(KProcess::Block); 
27
 
+
28
 
+    KProcess pXmodmapHome;
29
 
+    pXmodmapHome << "/usr/bin/xmodmap" << QDir::home().path() + "/.Xmodmap";
30
 
+    pXmodmapHome.start(KProcess::Block); 
31
 
+
32
 
+    return p.normalExit() && (p.exitStatus() == 0);
33
 
 }
34
 
 
35
 
 bool XKBExtension::setGroup(unsigned int group)