summaryrefslogtreecommitdiffstats
path: root/kxkb
diff options
context:
space:
mode:
Diffstat (limited to 'kxkb')
-rw-r--r--kxkb/extension.cpp16
1 files changed, 10 insertions, 6 deletions
diff --git a/kxkb/extension.cpp b/kxkb/extension.cpp
index 6946ab54f..3817a8c4c 100644
--- a/kxkb/extension.cpp
+++ b/kxkb/extension.cpp
@@ -180,13 +180,17 @@ bool XKBExtension::setLayoutInternal(const TQString& model,
p.start(KProcess::Block);
// reload system-wide hotkey-setup keycode -> keysym maps
- KProcess pXmodmap;
- pXmodmap << "xmodmap" << "/opt/trinity/share/apps/kxkb/system.xmodmap &> /dev/null";
- pXmodmap.start(KProcess::Block);
+ if ( TQFile::exists( "/opt/trinity/share/apps/kxkb/system.xmodmap" ) ) {
+ KProcess pXmodmap;
+ pXmodmap << "xmodmap" << "/opt/trinity/share/apps/kxkb/system.xmodmap";
+ pXmodmap.start(KProcess::Block);
+ }
- KProcess pXmodmapHome;
- pXmodmapHome << "xmodmap" << TQDir::home().path() + "/.Xmodmap &> /dev/null";
- pXmodmapHome.start(KProcess::Block);
+ if ( TQFile::exists( TQDir::home().path() + "/.Xmodmap" ) ) {
+ KProcess pXmodmapHome;
+ pXmodmapHome << "xmodmap" << TQDir::home().path() + "/.Xmodmap";
+ pXmodmapHome.start(KProcess::Block);
+ }
return p.normalExit() && (p.exitStatus() == 0);
}