|
1 /**************************************************************************** |
|
2 ** |
|
3 ** Copyright (C) 2008-2010 Nokia Corporation and/or its subsidiary(-ies). |
|
4 ** All rights reserved. |
|
5 ** Contact: Nokia Corporation (developer.feedback@nokia.com) |
|
6 ** |
|
7 ** This file is part of the HbCore module of the UI Extensions for Mobile. |
|
8 ** |
|
9 ** GNU Lesser General Public License Usage |
|
10 ** This file may be used under the terms of the GNU Lesser General Public |
|
11 ** License version 2.1 as published by the Free Software Foundation and |
|
12 ** appearing in the file LICENSE.LGPL included in the packaging of this file. |
|
13 ** Please review the following information to ensure the GNU Lesser General |
|
14 ** Public License version 2.1 requirements will be met: |
|
15 ** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. |
|
16 ** |
|
17 ** In addition, as a special exception, Nokia gives you certain additional |
|
18 ** rights. These rights are described in the Nokia Qt LGPL Exception |
|
19 ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. |
|
20 ** |
|
21 ** If you have questions regarding the use of this file, please contact |
|
22 ** Nokia at developer.feedback@nokia.com. |
|
23 ** |
|
24 ****************************************************************************/ |
|
25 |
|
26 #ifndef HBABSTRACTVKBHOST_P_H |
|
27 #define HBABSTRACTVKBHOST_P_H |
|
28 |
|
29 #include <QTimeLine> |
|
30 #include <QPointer> |
|
31 |
|
32 class QGraphicsWidget; |
|
33 class HbMainWindow; |
|
34 class HbVirtualKeyboard; |
|
35 class HbAbstractVkbHost; |
|
36 |
|
37 class HbPendingVkbHostCall |
|
38 { |
|
39 public: |
|
40 HbPendingVkbHostCall() : vkb(0), animationAllowed(false) {} |
|
41 |
|
42 public: |
|
43 HbVirtualKeyboard *vkb; |
|
44 bool animationAllowed; |
|
45 }; |
|
46 |
|
47 class HbAbstractVkbHostPrivate |
|
48 { |
|
49 public: |
|
50 HbAbstractVkbHostPrivate(HbAbstractVkbHost *myVkbHost, QGraphicsWidget *containerWidget); |
|
51 virtual ~HbAbstractVkbHostPrivate() {} |
|
52 |
|
53 virtual void openKeypad(); |
|
54 virtual void closeKeypad(); |
|
55 virtual void minimizeKeypad(); |
|
56 virtual void openMinimizedKeypad(); |
|
57 virtual void openKeypadWithoutAnimation(); |
|
58 virtual void closeKeypadWithoutAnimation(); |
|
59 virtual void minimizeKeypadWithoutAnimation(); |
|
60 virtual void cancelAnimationAndHideVkbWidget(); |
|
61 virtual bool prepareContainerAnimation(HbVkbHost::HbVkbStatus status); |
|
62 virtual bool prepareKeypadAnimation(HbVkbHost::HbVkbStatus status); |
|
63 |
|
64 void prepareAnimationsCommon(); |
|
65 bool prepareAnimations(HbVkbHost::HbVkbStatus status); |
|
66 |
|
67 virtual void connectSignals(); |
|
68 virtual void disconnectSignals(); |
|
69 |
|
70 HbMainWindow *mainWindow() const; |
|
71 QSizeF screenSize() const; |
|
72 bool disableCursorShift(); |
|
73 |
|
74 public: |
|
75 HbAbstractVkbHost *q_ptr; |
|
76 HbVirtualKeyboard *mCallback; |
|
77 QPointer<QGraphicsWidget> mKeypad; |
|
78 QPointer<QGraphicsWidget> mContainerWidget; |
|
79 QSizeF mScreenSize; |
|
80 QTimeLine mTimeLine; |
|
81 HbVkbHost::HbVkbStatus mKeypadStatus; |
|
82 bool mKeypadOperationOngoing; |
|
83 |
|
84 QPointF mOriginalContainerPosition; |
|
85 |
|
86 QPointF mContainerMovementStartingPoint; |
|
87 QPointF mContainerMovementVector; |
|
88 |
|
89 QPointF mKeypadMovementStartingPoint; |
|
90 QPointF mKeypadMovementVector; |
|
91 |
|
92 QPointer<HbInputMethod> mInputMethod; |
|
93 HbVkbHost::HbVkbStatus mKeypadStatusBeforeOrientationChange; |
|
94 bool mIsHiddenFlagSetByVkbHost; |
|
95 HbPendingVkbHostCall mPendingCall; |
|
96 }; |
|
97 |
|
98 #endif // HBABSTRACTVKBHOST_P_H |
|
99 |
|
100 // End of file |
|
101 |