17#ifndef LOMIRI_SHELL_APPLICATION_MIRSURFACEITEM_H
18#define LOMIRI_SHELL_APPLICATION_MIRSURFACEITEM_H
24#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
25Q_MOC_INCLUDE(
"MirSurfaceInterface.h")
35class MirSurfaceInterface;
66 Q_PROPERTY(QString
name READ
name NOTIFY nameChanged)
72 Q_PROPERTY(
bool live READ
live NOTIFY liveChanged)
80 NOTIFY orientationAngleChanged DESIGNABLE false)
89 WRITE setConsumesInput
90 NOTIFY consumesInputChanged)
99 NOTIFY surfaceWidthChanged)
107 WRITE setSurfaceHeight
108 NOTIFY surfaceHeightChanged)
110 Q_PROPERTY(FillMode fillMode READ fillMode WRITE setFillMode NOTIFY fillModeChanged)
127 virtual ~MirSurfaceItemInterface() {}
130 virtual QString
name()
const = 0;
131 virtual bool live()
const = 0;
138 virtual MirSurfaceInterface*
surface()
const = 0;
139 virtual void setSurface(MirSurfaceInterface*) = 0;
142 virtual void setConsumesInput(
bool value) = 0;
145 virtual void setSurfaceWidth(
int value) = 0;
148 virtual void setSurfaceHeight(
int value) = 0;
150 virtual FillMode fillMode()
const = 0;
151 virtual void setFillMode(FillMode value) = 0;
160 void liveChanged(
bool live);
163 void consumesInputChanged(
bool value);
164 void surfaceWidthChanged(
int value);
165 void surfaceHeightChanged(
int value);
166 void nameChanged(
const QString &
name);
167 void fillModeChanged(FillMode value);
Acting mostly as a namespace to hold enums and such for use in QML.
Definition Mir.h:26
State
Surface state.
Definition Mir.h:64
ShellChrome
Shell chrome.
Definition Mir.h:97
Type
Surface type.
Definition Mir.h:47
OrientationAngle
Surface orientation angle.
Definition Mir.h:86
Holds a Mir surface. Pretty much an opaque class.
Definition MirSurfaceInterface.h:46
Renders a MirSurface in a QML scene and forwards the input events it receives to it.
Definition MirSurfaceItemInterface.h:45
QString name
Name of the given surface or an empty string if no surface is set.
Definition MirSurfaceItemInterface.h:66
bool live
True if the item has a surface and that surface has a mir client bound to it. A "zombie" (live == fal...
Definition MirSurfaceItemInterface.h:72
lomiri::shell::application::MirSurfaceInterface * surface
The surface to be displayed.
Definition MirSurfaceItemInterface.h:51
Mir::Type type
Type of the given surface or Mir.UnknownType if no surface is set.
Definition MirSurfaceItemInterface.h:56
Mir::OrientationAngle orientationAngle
Orientation angle of the given surface.
Definition MirSurfaceItemInterface.h:80
int surfaceWidth
The desired width for the contained MirSurface. It's ignored if set to zero or a negative number The ...
Definition MirSurfaceItemInterface.h:99
int surfaceHeight
The desired height for the contained MirSurface. It's ignored if set to zero or a negative number The...
Definition MirSurfaceItemInterface.h:108
bool consumesInput
Whether the item will forward activeFocus, touch events, mouse events and key events to its surface....
Definition MirSurfaceItemInterface.h:90
Mir::ShellChrome shellChrome
The Shell chrome mode.
Definition MirSurfaceItemInterface.h:115
Mir::State surfaceState
State of the given surface or Mir.UnknownState if no surface is set.
Definition MirSurfaceItemInterface.h:61
Top-level namespace for all things Lomiri-related.
Definition Version.h:38