Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
qandroidplatformforeignwindow.h
Go to the documentation of this file.
1// Copyright (C) 2021 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QANDROIDPLATFORMFOREIGNWINDOW_H
5#define QANDROIDPLATFORMFOREIGNWINDOW_H
6
9
10#include <QtCore/QJniObject>
11
13
15{
16public:
17 explicit QAndroidPlatformForeignWindow(QWindow *window, WId nativeHandle);
19 void lower() override;
20 void raise() override;
21 void setGeometry(const QRect &rect) override;
22 void setVisible(bool visible) override;
24 void setParent(const QPlatformWindow *window) override;
25 bool isForeignWindow() const override { return true; }
26
27private:
28 int m_surfaceId;
29 QJniObject m_view;
30};
31
33
34#endif // QANDROIDPLATFORMFOREIGNWINDOW_H
void applicationStateChanged(Qt::ApplicationState state) override
void lower() override
Reimplement to be able to let Qt lower windows to the bottom of the desktop.
void setVisible(bool visible) override
Reimplemented in subclasses to show the surface if visible is true, and hide it if visible is false.
void setGeometry(const QRect &rect) override
This function is called by Qt whenever a window is moved or resized using the QWindow API.
void raise() override
Reimplement to be able to let Qt raise windows to the top of the desktop.
void setParent(const QPlatformWindow *window) override
This function is called to enable native child window in QPA.
\inmodule QtCore
The QPlatformWindow class provides an abstraction for top-level windows.
QWindow * window() const
Returns the window which belongs to the QPlatformWindow.
\inmodule QtCore\reentrant
Definition qrect.h:30
\inmodule QtGui
Definition qwindow.h:63
rect
[4]
else opt state
[0]
Combined button and popup list for selecting options.
ApplicationState
Definition qnamespace.h:261