1 /* * This file is part of Maliit framework * 2 * 3 * Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). 4 * All rights reserved. 5 * 6 * 7 * This library is free software; you can redistribute it and/or 8 * modify it under the terms of the GNU Lesser General Public 9 * License version 2.1 as published by the Free Software Foundation 10 * and appearing in the file LICENSE.LGPL included in the packaging 11 * of this file. 12 */ 13 14 #ifndef MALIIT_KEYBOARD_QUICK_H 15 #define MALIIT_KEYBOARD_QUICK_H 16 17 #include <QObject> 18 #include <maliit/namespace.h> 19 20 //! \brief MaliitQuick exposes Maliit enums to QML-based input methods 21 class MaliitQuick: public QObject 22 { 23 Q_OBJECT 24 Q_ENUMS(SwitchDirection) 25 Q_ENUMS(ContentType) 26 Q_ENUMS(KeyEvent) 27 Q_ENUMS(PreeditFace) 28 29 public: 30 //! This enum defines direction of plugin switching 31 enum SwitchDirection { 32 SwitchUndefined = Maliit::SwitchUndefined, //!< Special value for uninitialized variables 33 SwitchForward = Maliit::SwitchForward, //!< Activate next plugin 34 SwitchBackward = Maliit::SwitchBackward //!< Activate previous plugin 35 }; 36 37 enum ContentType { 38 FreeTextContentType = Maliit::FreeTextContentType, 39 NumberContentType = Maliit::NumberContentType, 40 PhoneNumberContentType = Maliit::PhoneNumberContentType, 41 EmailContentType = Maliit::EmailContentType, 42 UrlContentType = Maliit::UrlContentType, 43 CustomContentType = Maliit::CustomContentType 44 }; 45 46 enum KeyEvent { 47 KeyPress, 48 KeyRelease, 49 KeyClick 50 }; 51 52 enum PreeditFace { 53 PreeditDefault = Maliit::PreeditDefault, 54 PreeditNoCandidates = Maliit::PreeditNoCandidates, 55 PreeditKeyPress = Maliit::PreeditKeyPress 56 }; 57 }; 58 59 #endif // MALIIT_KEYBOARD_QUICK_H 60