Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qwaylandshell.cpp
Go to the documentation of this file.
1// Copyright (C) 2017 Pier Luigi Fiorini <pierluigi.fiorini@gmail.com>
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
3// Qt-Security score:significant reason:default
4
7
9
10QWaylandShellPrivate::QWaylandShellPrivate()
11{
12}
13
14QWaylandShell::QWaylandShell()
15{
16}
17
18QWaylandShell::QWaylandShell(QWaylandObject *waylandObject)
19 : QWaylandCompositorExtension(waylandObject, *new QWaylandShellPrivate())
20{
21}
22
23/*!
24 * \class QWaylandShell
25 * \inmodule QtWaylandCompositor
26 * \abstract
27 * \brief Abstract class for implementing a wayland shell.
28 */
29
30/*!
31 * \enum QWaylandShell::FocusPolicy
32 *
33 * This enum type is used to specify the focus policy for shell surfaces.
34 *
35 * \value AutomaticFocus Shell surfaces will automatically get keyboard focus when they are created.
36 * \value ManualFocus The compositor will decide whether shell surfaces should get keyboard focus or not.
37 */
38
39/*!
40 * \qmltype Shell
41 * \nativetype QWaylandShell
42 * \inqmlmodule QtWayland.Compositor
43 * \brief Abrtract type for implementing a wayland shell.
44 */
45
46/*!
47 * \qmlproperty enumeration Shell::focusPolicy
48 *
49 * This property holds the focus policy of the Shell.
50 */
51
52/*!
53 * \property QWaylandShell::focusPolicy
54 *
55 * This property holds the focus policy of the QWaylandShell.
56 */
57QWaylandShell::FocusPolicy QWaylandShell::focusPolicy() const
58{
59 Q_D(const QWaylandShell);
60 return d->focusPolicy;
61}
62
63void QWaylandShell::setFocusPolicy(QWaylandShell::FocusPolicy focusPolicy)
64{
65 Q_D(QWaylandShell);
66
67 if (d->focusPolicy == focusPolicy)
68 return;
69
70 d->focusPolicy = focusPolicy;
71 emit focusPolicyChanged();
72}
73
74QWaylandShell::QWaylandShell(QWaylandShellPrivate &dd)
75 : QWaylandCompositorExtension(dd)
76{
77}
78
79QWaylandShell::QWaylandShell(QWaylandObject *container, QWaylandShellPrivate &dd)
80 : QWaylandCompositorExtension(container, dd)
81{
82}
83
84QT_END_NAMESPACE
85
86#include "moc_qwaylandshell.cpp"
Combined button and popup list for selecting options.