add more spacing
[personal-kdebase.git] / workspace / libs / kworkspace / kwindowlistmenu.h
blob2fe601be8bbb3ef6b55700ad4ca3b54b8df7e626
1 /*****************************************************************
3 Copyright (c) 2000 Matthias Elter <elter@kde.org>
4 Matthias Ettrich <ettrich@kde.org>
6 Permission is hereby granted, free of charge, to any person obtaining a copy
7 of this software and associated documentation files (the "Software"), to deal
8 in the Software without restriction, including without limitation the rights
9 to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10 copies of the Software, and to permit persons to whom the Software is
11 furnished to do so, subject to the following conditions:
13 The above copyright notice and this permission notice shall be included in
14 all copies or substantial portions of the Software.
16 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19 AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
20 AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
21 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23 ******************************************************************/
25 #ifndef KWINDOWLISTMENU_H
26 #define KWINDOWLISTMENU_H
28 #include <kdemacros.h>
29 #include <kmenu.h>
31 /**
32 * This class provides a menu which contains actions
33 * to manage a window. It is used by the window manager
34 * for example an accessable there via the menu button of
35 * the window decoration.
37 class KDE_EXPORT KWindowListMenu : public KMenu
39 Q_OBJECT
41 public:
42 /**
43 * Creates a new window list menu.
45 * @param parent The parent widget.
47 explicit KWindowListMenu( QWidget *parent = 0 );
49 /**
50 * Destroys the window list menu.
52 virtual ~KWindowListMenu();
54 /**
55 * Initializes the menu by filling it with actions
56 * for managing a window.
58 void init();
60 public Q_SLOTS:
61 /**
62 * Pre-selects the active window in the popup menu, for faster
63 * keyboard navigation. Needs to be called after popup().
64 * Should not be used when the popup is invoked using the mouse.
66 void selectActiveWindow();
68 protected Q_SLOTS:
69 void slotForceActiveWindow();
70 void slotSetCurrentDesktop();
71 void slotUnclutterWindows();
72 void slotCascadeWindows();
74 private:
75 class Private;
76 Private* const d;
79 #endif