fix tricky regression noticed by Vyacheslav Tokarev on Google Reader.
[kdelibs.git] / kdeui / util / kkeyserver.h
blobe95db50341595723f4d13e623afa061ebfabc054
1 /*
2 Copyright (C) 2001 Ellis Whitehead <ellis@kde.org>
4 Win32 port:
5 Copyright (C) 2004 Jarosław Staniek <staniek@kde.org>
7 This library is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Library General Public
9 License as published by the Free Software Foundation; either
10 version 2 of the License, or (at your option) any later version.
12 This library is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 Library General Public License for more details.
17 You should have received a copy of the GNU Library General Public License
18 along with this library; see the file COPYING.LIB. If not, write to
19 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20 Boston, MA 02110-1301, USA.
23 #ifndef _KKEYSERVER_H
24 #define _KKEYSERVER_H
26 #include <kdeui_export.h>
28 #if defined Q_WS_X11 /*or defined Q_WS_WIN*/
29 #include "kkeyserver_x11.h"
30 #elif defined Q_WS_MACX
31 #include "kkeyserver_mac.h"
32 #elif defined Q_WS_WIN
33 #include "kkeyserver_win.h"
34 #endif
36 /**
37 * A collection of functions for the conversion of key presses and
38 * their modifiers from the window system specific format
39 * to the generic format and vice-versa.
41 namespace KKeyServer {
42 /**
43 * Converts the mask of ORed KKey::ModFlag modifiers to a
44 * user-readable string.
45 * @param mod the mask of ORed KKey::ModFlag modifiers
46 * @return the user-readable string
48 KDEUI_EXPORT QString modToStringUser( uint mod );
50 /**
51 * Converts the modifier given as user-readable string
52 * to KKey::ModFlag modifier, or 0.
53 * @internal
55 KDEUI_EXPORT uint stringUserToMod( const QString& mod );
56 } // namespace KKeyServer
58 #endif // !_KKEYSERVER_H