diff options
author | Christian Strømme <christian.stromme@digia.com> | 2014-08-28 12:18:14 +0200 |
---|---|---|
committer | Christian Stromme <christian.stromme@digia.com> | 2014-09-26 23:44:42 +0200 |
commit | 8b0d9a16db7bcfb5d6439b8863aded5c583f9ed5 (patch) | |
tree | 5fca60950d6e7dba1f12f9ceda0e564965d35116 /src/plugins/platforms/android/qandroidplatformforeignwindow.h | |
parent | c30687f519de47279a70c3eca95eec2191eddbb1 (diff) |
Android: Improve the foreign-window implementation
Adds:
- Improved geometry calculations (e.g, inside a parent)
- Change visibility
- proper stacking order. Native views now reserve the top of the stack
to ensure that they stay visible.
- React to application state changes.
Change-Id: I35de0396937fff37ffcd272c9a7d8e9873a91dfb
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
Diffstat (limited to 'src/plugins/platforms/android/qandroidplatformforeignwindow.h')
-rw-r--r-- | src/plugins/platforms/android/qandroidplatformforeignwindow.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/plugins/platforms/android/qandroidplatformforeignwindow.h b/src/plugins/platforms/android/qandroidplatformforeignwindow.h index cb04142696..974ffbc376 100644 --- a/src/plugins/platforms/android/qandroidplatformforeignwindow.h +++ b/src/plugins/platforms/android/qandroidplatformforeignwindow.h @@ -38,16 +38,23 @@ #include "qandroidplatformwindow.h" #include <QtCore/private/qjni_p.h> +QT_BEGIN_NAMESPACE + class QAndroidPlatformForeignWindow : public QAndroidPlatformWindow { public: explicit QAndroidPlatformForeignWindow(QWindow *window); ~QAndroidPlatformForeignWindow(); - void setGeometry(const QRect &rect); + void setGeometry(const QRect &rect) Q_DECL_OVERRIDE; + void setVisible(bool visible) Q_DECL_OVERRIDE; + void applicationStateChanged(Qt::ApplicationState state) Q_DECL_OVERRIDE; + void setParent(const QPlatformWindow *window) Q_DECL_OVERRIDE; private: + int m_surfaceId; QJNIObjectPrivate m_view; - int m_surfaceId = -1; }; +QT_END_NAMESPACE + #endif // QANDROIDPLATFORMFOREIGNWINDOW_H |