setGlobalShortcut() for global shortcuts
svn path=/trunk/KDE/kdebase/workspace/; revision=568236
This commit is contained in:
parent
b5d2f22925
commit
bffa0d7909
1 changed files with 4 additions and 4 deletions
|
@ -1,19 +1,19 @@
|
|||
#ifndef NOSLOTS
|
||||
# define DEF2( name, descr, key, fnSlot ) \
|
||||
a = new KAction( i18n(descr), actionCollection, name ); \
|
||||
a->setShortcut(KShortcut(key)); \
|
||||
a->setGlobalShortcut(KShortcut(key)); \
|
||||
connect(a, SIGNAL(triggered(bool)), SLOT(fnSlot))
|
||||
# define DEF( name, key, fnSlot ) \
|
||||
a = new KAction( i18n(name), actionCollection, name ); \
|
||||
a->setShortcut(KShortcut(key)); \
|
||||
a->setGlobalShortcut(KShortcut(key)); \
|
||||
connect(a, SIGNAL(triggered(bool)), SLOT(fnSlot))
|
||||
#else
|
||||
# define DEF2( name, descr, key, fnSlot ) \
|
||||
a = new KAction( i18n(descr), actionCollection, name ); \
|
||||
a->setShortcut(KShortcut(key));
|
||||
a->setGlobalShortcut(KShortcut(key));
|
||||
# define DEF( name, key, fnSlot ) \
|
||||
a = new KAction( i18n(name), actionCollection, name ); \
|
||||
a->setShortcut(KShortcut(key));
|
||||
a->setGlobalShortcut(KShortcut(key));
|
||||
#endif
|
||||
|
||||
// some shortcuts have Tarzan-speech like names, they need extra normal human descriptions with DEF2()
|
||||
|
|
Loading…
Reference in a new issue