merge in r568494 from trunk
svn path=/branches/work/kwin_composite/; revision=590656
This commit is contained in:
parent
649887d6c2
commit
9cfa570153
2 changed files with 76 additions and 36 deletions
|
@ -1,19 +1,19 @@
|
|||
#ifndef NOSLOTS
|
||||
# define DEF2( name, descr, key, fnSlot ) \
|
||||
a = new KAction( i18n(descr), actionCollection, name ); \
|
||||
a->setGlobalShortcut(KShortcut(key)); \
|
||||
a->setShortcut(KShortcut(key)); \
|
||||
connect(a, SIGNAL(triggered(bool)), SLOT(fnSlot))
|
||||
# define DEF( name, key, fnSlot ) \
|
||||
a = new KAction( i18n(name), actionCollection, name ); \
|
||||
a->setGlobalShortcut(KShortcut(key)); \
|
||||
a->setShortcut(KShortcut(key)); \
|
||||
connect(a, SIGNAL(triggered(bool)), SLOT(fnSlot))
|
||||
#else
|
||||
# define DEF2( name, descr, key, fnSlot ) \
|
||||
a = new KAction( i18n(descr), actionCollection, name ); \
|
||||
a->setGlobalShortcut(KShortcut(key));
|
||||
a->setShortcut(KShortcut(key));
|
||||
# define DEF( name, key, fnSlot ) \
|
||||
a = new KAction( i18n(name), actionCollection, name ); \
|
||||
a->setGlobalShortcut(KShortcut(key));
|
||||
a->setShortcut(KShortcut(key));
|
||||
#endif
|
||||
|
||||
// some shortcuts have Tarzan-speech like names, they need extra normal human descriptions with DEF2()
|
||||
|
@ -24,25 +24,25 @@
|
|||
new KAction( i18n("Navigation"), actionCollection, "Group:Navigation" );
|
||||
DEF( I18N_NOOP("Walk Through Windows"), Qt::ALT+Qt::Key_Tab, slotWalkThroughWindows() );
|
||||
DEF( I18N_NOOP("Walk Through Windows (Reverse)"), Qt::ALT+Qt::SHIFT+Qt::Key_Tab, slotWalkBackThroughWindows() );
|
||||
DEF( I18N_NOOP("Walk Through Desktops"), 0, slotWalkThroughDesktops() );
|
||||
DEF( I18N_NOOP("Walk Through Desktops (Reverse)"), 0, slotWalkBackThroughDesktops() );
|
||||
DEF( I18N_NOOP("Walk Through Desktops"), Qt::META+Qt::Key_Tab, slotWalkThroughDesktops() );
|
||||
DEF( I18N_NOOP("Walk Through Desktops (Reverse)"), Qt::META+Qt::SHIFT+Qt::Key_Tab, slotWalkBackThroughDesktops() );
|
||||
DEF( I18N_NOOP("Walk Through Desktop List"), 0, slotWalkThroughDesktopList() );
|
||||
DEF( I18N_NOOP("Walk Through Desktop List (Reverse)"), 0, slotWalkBackThroughDesktopList() );
|
||||
|
||||
new KAction( i18n("Windows"), actionCollection, "Group:Windows" );
|
||||
DEF( I18N_NOOP("Window Operations Menu"), Qt::ALT+Qt::Key_F3, slotWindowOperations() );
|
||||
DEF( I18N_NOOP("Window Operations Menu"), Qt::ALT+Qt::Key_Menu, slotWindowOperations() );
|
||||
DEF2( "Window Close", I18N_NOOP("Close Window"),
|
||||
Qt::ALT+Qt::Key_F4, slotWindowClose() );
|
||||
"Alt+Escape;Alt+F4", slotWindowClose() );
|
||||
DEF2( "Window Maximize", I18N_NOOP("Maximize Window"),
|
||||
0, slotWindowMaximize() );
|
||||
Qt::META+Qt::Key_Plus, slotWindowMaximize() );
|
||||
DEF2( "Window Maximize Vertical", I18N_NOOP("Maximize Window Vertically"),
|
||||
0, slotWindowMaximizeVertical() );
|
||||
Qt::META+Qt::Key_Bar, slotWindowMaximizeVertical() );
|
||||
DEF2( "Window Maximize Horizontal", I18N_NOOP("Maximize Window Horizontally"),
|
||||
0, slotWindowMaximizeHorizontal() );
|
||||
Qt::META+Qt::Key_Equal, slotWindowMaximizeHorizontal() );
|
||||
DEF2( "Window Minimize", I18N_NOOP("Minimize Window"),
|
||||
0, slotWindowMinimize() );
|
||||
Qt::META+Qt::Key_Minus, slotWindowMinimize() );
|
||||
DEF2( "Window Shade", I18N_NOOP("Shade Window"),
|
||||
0, slotWindowShade() );
|
||||
Qt::META+Qt::Key_Underscore, slotWindowShade() );
|
||||
DEF2( "Window Move", I18N_NOOP("Move Window"),
|
||||
0, slotWindowMove() );
|
||||
DEF2( "Window Resize", I18N_NOOP("Resize Window"),
|
||||
|
@ -84,16 +84,16 @@
|
|||
new KAction( i18n("Window & Desktop"), actionCollection, "Group:Window Desktop" );
|
||||
DEF2( "Window On All Desktops", I18N_NOOP("Keep Window on All Desktops"),
|
||||
0, slotWindowOnAllDesktops() );
|
||||
DEF( I18N_NOOP("Window to Desktop 1"), 0, slotWindowToDesktop1() );
|
||||
DEF( I18N_NOOP("Window to Desktop 2"), 0, slotWindowToDesktop2() );
|
||||
DEF( I18N_NOOP("Window to Desktop 3"), 0, slotWindowToDesktop3() );
|
||||
DEF( I18N_NOOP("Window to Desktop 4"), 0, slotWindowToDesktop4() );
|
||||
DEF( I18N_NOOP("Window to Desktop 5"), 0, slotWindowToDesktop5() );
|
||||
DEF( I18N_NOOP("Window to Desktop 6"), 0, slotWindowToDesktop6() );
|
||||
DEF( I18N_NOOP("Window to Desktop 7"), 0, slotWindowToDesktop7() );
|
||||
DEF( I18N_NOOP("Window to Desktop 8"), 0, slotWindowToDesktop8() );
|
||||
DEF( I18N_NOOP("Window to Desktop 9"), 0, slotWindowToDesktop9() );
|
||||
DEF( I18N_NOOP("Window to Desktop 10"), 0, slotWindowToDesktop10() );
|
||||
DEF( I18N_NOOP("Window to Desktop 1"), Qt::META+Qt::ALT+Qt::Key_F1, slotWindowToDesktop1() );
|
||||
DEF( I18N_NOOP("Window to Desktop 2"), Qt::META+Qt::ALT+Qt::Key_F2, slotWindowToDesktop2() );
|
||||
DEF( I18N_NOOP("Window to Desktop 3"), Qt::META+Qt::ALT+Qt::Key_F3, slotWindowToDesktop3() );
|
||||
DEF( I18N_NOOP("Window to Desktop 4"), Qt::META+Qt::ALT+Qt::Key_F4, slotWindowToDesktop4() );
|
||||
DEF( I18N_NOOP("Window to Desktop 5"), Qt::META+Qt::ALT+Qt::Key_F5, slotWindowToDesktop5() );
|
||||
DEF( I18N_NOOP("Window to Desktop 6"), Qt::META+Qt::ALT+Qt::Key_F6, slotWindowToDesktop6() );
|
||||
DEF( I18N_NOOP("Window to Desktop 7"), Qt::META+Qt::ALT+Qt::Key_F7, slotWindowToDesktop7() );
|
||||
DEF( I18N_NOOP("Window to Desktop 8"), Qt::META+Qt::ALT+Qt::Key_F8, slotWindowToDesktop8() );
|
||||
DEF( I18N_NOOP("Window to Desktop 9"), Qt::META+Qt::ALT+Qt::Key_F9, slotWindowToDesktop9() );
|
||||
DEF( I18N_NOOP("Window to Desktop 10"), Qt::META+Qt::ALT+Qt::Key_F10, slotWindowToDesktop10() );
|
||||
DEF( I18N_NOOP("Window to Desktop 11"), 0, slotWindowToDesktop11() );
|
||||
DEF( I18N_NOOP("Window to Desktop 12"), 0, slotWindowToDesktop12() );
|
||||
DEF( I18N_NOOP("Window to Desktop 13"), 0, slotWindowToDesktop13() );
|
||||
|
@ -112,16 +112,16 @@
|
|||
DEF( I18N_NOOP("Window One Desktop Down"), 0, slotWindowToDesktopDown() );
|
||||
|
||||
new KAction( i18n("Desktop Switching"), actionCollection, "Group:Desktop Switching" );
|
||||
DEF( I18N_NOOP("Switch to Desktop 1"), Qt::CTRL+Qt::Key_F1, slotSwitchToDesktop1() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 2"), Qt::CTRL+Qt::Key_F2, slotSwitchToDesktop2() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 3"), Qt::CTRL+Qt::Key_F3, slotSwitchToDesktop3() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 4"), Qt::CTRL+Qt::Key_F4, slotSwitchToDesktop4() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 5"), Qt::CTRL+Qt::Key_F5, slotSwitchToDesktop5() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 6"), Qt::CTRL+Qt::Key_F6, slotSwitchToDesktop6() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 7"), Qt::CTRL+Qt::Key_F7, slotSwitchToDesktop7() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 8"), Qt::CTRL+Qt::Key_F8, slotSwitchToDesktop8() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 9"), Qt::CTRL+Qt::Key_F9, slotSwitchToDesktop9() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 10"), Qt::CTRL+Qt::Key_F10, slotSwitchToDesktop10() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 1"), Qt::META+Qt::Key_F1, slotSwitchToDesktop1() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 2"), Qt::META+Qt::Key_F2, slotSwitchToDesktop2() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 3"), Qt::META+Qt::Key_F3, slotSwitchToDesktop3() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 4"), Qt::META+Qt::Key_F4, slotSwitchToDesktop4() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 5"), Qt::META+Qt::Key_F5, slotSwitchToDesktop5() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 6"), Qt::META+Qt::Key_F6, slotSwitchToDesktop6() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 7"), Qt::META+Qt::Key_F7, slotSwitchToDesktop7() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 8"), Qt::META+Qt::Key_F8, slotSwitchToDesktop8() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 9"), Qt::META+Qt::Key_F9, slotSwitchToDesktop9() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 10"), Qt::META+Qt::Key_F10, slotSwitchToDesktop10() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 11"), Qt::CTRL+Qt::Key_F11, slotSwitchToDesktop11() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 12"), Qt::CTRL+Qt::Key_F12, slotSwitchToDesktop12() );
|
||||
DEF( I18N_NOOP("Switch to Desktop 13"), Qt::CTRL+Qt::SHIFT+Qt::Key_F1, slotSwitchToDesktop13() );
|
||||
|
@ -141,9 +141,9 @@
|
|||
|
||||
new KAction( i18n("Miscellaneous"), actionCollection, "Group:Miscellaneous" );
|
||||
DEF( I18N_NOOP("Mouse Emulation"), Qt::ALT+Qt::Key_F12, slotMouseEmulation() );
|
||||
DEF( I18N_NOOP("Kill Window"), Qt::CTRL+Qt::Key_Delete, slotKillWindow() );
|
||||
DEF( I18N_NOOP("Window Screenshot To Clipboard"), Qt::ALT+Qt::Key_Print, slotGrabWindow() );
|
||||
DEF( I18N_NOOP("Desktop Screenshot To Clipboard"), Qt::CTRL+Qt::Key_Print, slotGrabDesktop() );
|
||||
DEF( I18N_NOOP("Kill Window"), Qt::META+Qt::CTRL+Qt::Key_Delete, slotKillWindow() );
|
||||
DEF( I18N_NOOP("Window Screenshot"), Qt::ALT+Qt::Key_Print, slotGrabWindow() );
|
||||
DEF( I18N_NOOP("Desktop Screenshot"), Qt::META+Qt::Key_Print, slotGrabDesktop() );
|
||||
DEF( I18N_NOOP("Block Global Shortcuts"), 0, slotDisableGlobalShortcuts());
|
||||
|
||||
/*This belongs in taskbar rather than here, so it'll have to wait until after 2.2 is done.
|
||||
|
|
40
workspace.h
40
workspace.h
|
@ -301,8 +301,48 @@ class Workspace : public QObject, public KDecorationDefines
|
|||
void slotSwitchDesktopDown();
|
||||
|
||||
void slotSwitchToDesktop( int );
|
||||
void slotSwitchToDesktop1() { return slotSwitchToDesktop( 1 ); }
|
||||
void slotSwitchToDesktop2() { return slotSwitchToDesktop( 2 ); }
|
||||
void slotSwitchToDesktop3() { return slotSwitchToDesktop( 3 ); }
|
||||
void slotSwitchToDesktop4() { return slotSwitchToDesktop( 4 ); }
|
||||
void slotSwitchToDesktop5() { return slotSwitchToDesktop( 5 ); }
|
||||
void slotSwitchToDesktop6() { return slotSwitchToDesktop( 6 ); }
|
||||
void slotSwitchToDesktop7() { return slotSwitchToDesktop( 7 ); }
|
||||
void slotSwitchToDesktop8() { return slotSwitchToDesktop( 8 ); }
|
||||
void slotSwitchToDesktop9() { return slotSwitchToDesktop( 9 ); }
|
||||
void slotSwitchToDesktop10() { return slotSwitchToDesktop( 10 ); }
|
||||
void slotSwitchToDesktop11() { return slotSwitchToDesktop( 11 ); }
|
||||
void slotSwitchToDesktop12() { return slotSwitchToDesktop( 12 ); }
|
||||
void slotSwitchToDesktop13() { return slotSwitchToDesktop( 13 ); }
|
||||
void slotSwitchToDesktop14() { return slotSwitchToDesktop( 14 ); }
|
||||
void slotSwitchToDesktop15() { return slotSwitchToDesktop( 15 ); }
|
||||
void slotSwitchToDesktop16() { return slotSwitchToDesktop( 16 ); }
|
||||
void slotSwitchToDesktop17() { return slotSwitchToDesktop( 17 ); }
|
||||
void slotSwitchToDesktop18() { return slotSwitchToDesktop( 18 ); }
|
||||
void slotSwitchToDesktop19() { return slotSwitchToDesktop( 19 ); }
|
||||
void slotSwitchToDesktop20() { return slotSwitchToDesktop( 20 ); }
|
||||
//void slotSwitchToWindow( int );
|
||||
void slotWindowToDesktop( int );
|
||||
void slotWindowToDesktop1() { return slotWindowToDesktop( 1 ); }
|
||||
void slotWindowToDesktop2() { return slotWindowToDesktop( 2 ); }
|
||||
void slotWindowToDesktop3() { return slotWindowToDesktop( 3 ); }
|
||||
void slotWindowToDesktop4() { return slotWindowToDesktop( 4 ); }
|
||||
void slotWindowToDesktop5() { return slotWindowToDesktop( 5 ); }
|
||||
void slotWindowToDesktop6() { return slotWindowToDesktop( 6 ); }
|
||||
void slotWindowToDesktop7() { return slotWindowToDesktop( 7 ); }
|
||||
void slotWindowToDesktop8() { return slotWindowToDesktop( 8 ); }
|
||||
void slotWindowToDesktop9() { return slotWindowToDesktop( 9 ); }
|
||||
void slotWindowToDesktop10() { return slotWindowToDesktop( 10 ); }
|
||||
void slotWindowToDesktop11() { return slotWindowToDesktop( 11 ); }
|
||||
void slotWindowToDesktop12() { return slotWindowToDesktop( 12 ); }
|
||||
void slotWindowToDesktop13() { return slotWindowToDesktop( 13 ); }
|
||||
void slotWindowToDesktop14() { return slotWindowToDesktop( 14 ); }
|
||||
void slotWindowToDesktop15() { return slotWindowToDesktop( 15 ); }
|
||||
void slotWindowToDesktop16() { return slotWindowToDesktop( 16 ); }
|
||||
void slotWindowToDesktop17() { return slotWindowToDesktop( 17 ); }
|
||||
void slotWindowToDesktop18() { return slotWindowToDesktop( 18 ); }
|
||||
void slotWindowToDesktop19() { return slotWindowToDesktop( 19 ); }
|
||||
void slotWindowToDesktop20() { return slotWindowToDesktop( 20 ); }
|
||||
//void slotWindowToListPosition( int );
|
||||
|
||||
void slotWindowMaximize();
|
||||
|
|
Loading…
Reference in a new issue