Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qwaylandwindowmanagerintegration.cpp
Go to the documentation of this file.
1// Copyright (C) 2016 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
5#include "qwaylandscreen_p.h"
6#include "qwaylandwindow_p.h"
7#include "qwaylanddisplay_p.h"
9
10#include <stdint.h>
11#include <QtCore/QEvent>
12#include <QtCore/QHash>
13#include <QtCore/QUrl>
14#include <qpa/qplatformnativeinterface.h>
15#include <qpa/qplatformwindow.h>
16#include <QtGui/QtEvents>
17#include <QtGui/QGuiApplication>
18
19#include <QDebug>
20
22
23namespace QtWaylandClient {
24
26 uint id, uint version)
27 : QtWayland::qt_windowmanager(waylandDisplay->object(), id, version)
28{
29}
30
32{
33 qt_windowmanager_destroy(object());
34}
35
37{
38 return m_showIsFullScreen;
39}
40
42{
43 m_showIsFullScreen = showIsFullScreen;
44}
45
50
52{
54 static const int chunkSize = 128;
55 while (!data.isEmpty()) {
56 QString chunk = data.left(chunkSize);
57 data = data.mid(chunkSize);
58 if (chunk.at(chunk.size() - 1).isHighSurrogate() && !data.isEmpty()) {
59 chunk.append(data.at(0));
60 data = data.mid(1);
61 }
62 open_url(!data.isEmpty(), chunk);
63 }
64}
65}
66
68
69#include "moc_qwaylandwindowmanagerintegration_p.cpp"
static void quit()
\threadsafe
\macro QT_RESTRICTED_CAST_FROM_ASCII
Definition qstring.h:129
QString left(qsizetype n) const &
Definition qstring.h:363
QString mid(qsizetype position, qsizetype n=-1) const &
Definition qstring.cpp:5300
qsizetype size() const noexcept
Returns the number of characters in this string.
Definition qstring.h:186
const QChar at(qsizetype i) const
Returns the character at the given index position in the string.
Definition qstring.h:1226
QString & append(QChar c)
Definition qstring.cpp:3252
\inmodule QtCore
Definition qurl.h:94
QString toString(FormattingOptions options=FormattingOptions(PrettyDecoded)) const
Returns a string representation of the URL.
Definition qurl.cpp:2831
QWaylandWindowManagerIntegration(QWaylandDisplay *waylandDisplay, uint id, uint version)
Combined button and popup list for selecting options.
GLenum GLuint id
[7]
GLuint object
[3]
GLint GLsizei GLsizei GLenum GLenum GLsizei void * data
unsigned int uint
Definition qtypes.h:34
QUrl url("example.com")
[constructor-url-reference]