6#include <PhosphorShell/phosphorshell_export.h>
10#include <QAbstractListModel>
14#include <QtQml/qqmlregistration.h>
47 ToplevelRole = Qt::UserRole + 1
54 [[nodiscard]]
int rowCount(const QModelIndex& parent = {})
const override;
55 [[nodiscard]] QVariant
data(
const QModelIndex& index,
int role)
const override;
56 [[nodiscard]] QHash<int, QByteArray>
roleNames()
const override;
63 QPointer<PhosphorWayland::ForeignToplevelManager> m_manager;
67 QList<QPointer<PhosphorWayland::ForeignToplevel>> m_rows;
113 Q_PROPERTY(QList<PhosphorWayland::ForeignToplevel*> toplevels READ toplevels NOTIFY toplevelsChanged)
117 Q_PROPERTY(QAbstractListModel* model READ model CONSTANT)
118 Q_PROPERTY(
bool supported READ isSupported CONSTANT)
127 [[nodiscard]] QList<PhosphorWayland::ForeignToplevel*>
toplevels()
const;
128 [[nodiscard]] QAbstractListModel*
model()
const;
QAbstractListModel view of the live toplevel set.
Definition Toplevels.h:42
QVariant data(const QModelIndex &index, int role) const override
Role
Definition Toplevels.h:46
QHash< int, QByteArray > roleNames() const override
QML singleton exposing the live list of toplevel windows for taskbars.
Definition Toplevels.h:104
Toplevels(QObject *parent=nullptr)
Snapshot list of currently-live toplevels.
static Toplevels * create(QQmlEngine *engine, QJSEngine *scriptEngine)
QML-singleton factory hook.
QAbstractListModel * model() const
QList< PhosphorWayland::ForeignToplevel * > toplevels() const
Client-side wrapper around zwlr_foreign_toplevel_manager_v1.
Definition ForeignToplevel.h:44
A single toplevel window owned by some other Wayland client.
Definition ForeignToplevel.h:91
Definition Environment.h:11
Definition CompositorLost.h:11