Changeset View
Changeset View
Standalone View
Standalone View
virtualkeyboard.h
Show All 19 Lines | |||||
20 | #ifndef KWIN_VIRTUAL_KEYBOARD_H | 20 | #ifndef KWIN_VIRTUAL_KEYBOARD_H | ||
21 | #define KWIN_VIRTUAL_KEYBOARD_H | 21 | #define KWIN_VIRTUAL_KEYBOARD_H | ||
22 | 22 | | |||
23 | #include <QObject> | 23 | #include <QObject> | ||
24 | 24 | | |||
25 | #include <kwinglobals.h> | 25 | #include <kwinglobals.h> | ||
26 | #include <kwin_export.h> | 26 | #include <kwin_export.h> | ||
27 | 27 | | |||
28 | #include <abstract_client.h> | ||||
29 | | ||||
28 | class QQuickView; | 30 | class QQuickView; | ||
romangg: Necessary? | |||||
31 | class QTimer; | ||||
29 | class QWindow; | 32 | class QWindow; | ||
30 | class KStatusNotifierItem; | 33 | class KStatusNotifierItem; | ||
31 | 34 | | |||
32 | namespace KWin | 35 | namespace KWin | ||
33 | { | 36 | { | ||
34 | 37 | | |||
35 | class KWIN_EXPORT VirtualKeyboard : public QObject | 38 | class KWIN_EXPORT VirtualKeyboard : public QObject | ||
36 | { | 39 | { | ||
Show All 11 Lines | |||||
48 | Q_SIGNALS: | 51 | Q_SIGNALS: | ||
49 | void enabledChanged(bool enabled); | 52 | void enabledChanged(bool enabled); | ||
50 | 53 | | |||
51 | private: | 54 | private: | ||
52 | void show(); | 55 | void show(); | ||
53 | void hide(); | 56 | void hide(); | ||
54 | void setEnabled(bool enable); | 57 | void setEnabled(bool enable); | ||
55 | void updateSni(); | 58 | void updateSni(); | ||
59 | void updateInputPanelState(); | ||||
56 | 60 | | |||
57 | bool m_enabled = false; | 61 | bool m_enabled = false; | ||
58 | KStatusNotifierItem *m_sni = nullptr; | 62 | KStatusNotifierItem *m_sni = nullptr; | ||
59 | QScopedPointer<QQuickView> m_inputWindow; | 63 | QScopedPointer<QQuickView> m_inputWindow; | ||
64 | QPointer<AbstractClient> m_trackedClient; | ||||
65 | // If a surface loses focus immediately after being resized by the keyboard, don't react to it to avoid resize loops | ||||
66 | QTimer *m_floodTimer; | ||||
67 | | ||||
60 | QMetaObject::Connection m_waylandShowConnection; | 68 | QMetaObject::Connection m_waylandShowConnection; | ||
61 | QMetaObject::Connection m_waylandHideConnection; | 69 | QMetaObject::Connection m_waylandHideConnection; | ||
62 | QMetaObject::Connection m_waylandHintsConnection; | 70 | QMetaObject::Connection m_waylandHintsConnection; | ||
63 | QMetaObject::Connection m_waylandSurroundingTextConnection; | 71 | QMetaObject::Connection m_waylandSurroundingTextConnection; | ||
64 | QMetaObject::Connection m_waylandResetConnection; | 72 | QMetaObject::Connection m_waylandResetConnection; | ||
65 | QMetaObject::Connection m_waylandEnabledConnection; | 73 | QMetaObject::Connection m_waylandEnabledConnection; | ||
66 | KWIN_SINGLETON(VirtualKeyboard) | 74 | KWIN_SINGLETON(VirtualKeyboard) | ||
67 | }; | 75 | }; | ||
68 | 76 | | |||
69 | } | 77 | } | ||
70 | 78 | | |||
71 | #endif | 79 | #endif |
Necessary?