@@ -32,6 +32,7 @@ class MirSurfaceItem : public QQuickItem
32 Q_PROPERTY(Type type READ type NOTIFY typeChanged)
32 Q_PROPERTY(Type type READ type NOTIFY typeChanged)
33 Q_PROPERTY(State state READ state NOTIFY stateChanged)
33 Q_PROPERTY(State state READ state NOTIFY stateChanged)
34 Q_PROPERTY(QString name READ name NOTIFY nameChanged)
34 Q_PROPERTY(QString name READ name NOTIFY nameChanged)
35+ Q_PROPERTY(Qt::ScreenOrientation orientation READ orientation WRITE setOrientation NOTIFY orientationChanged DESIGNABLE false)
35 Q_PROPERTY(MirSurfaceItem* parentSurface READ parentSurface NOTIFY parentSurfaceChanged)
36 Q_PROPERTY(MirSurfaceItem* parentSurface READ parentSurface NOTIFY parentSurfaceChanged)
36 Q_PROPERTY(QQmlListProperty<MirSurfaceItem> childSurfaces READ childSurfaces NOTIFY childSurfacesChanged DESIGNABLE false)
37 Q_PROPERTY(QQmlListProperty<MirSurfaceItem> childSurfaces READ childSurfaces NOTIFY childSurfacesChanged DESIGNABLE false)
@@ -69,9 +70,11 @@ public:
69 Type type() const { return m_type; }
70 Type type() const { return m_type; }
70 State state() const { return m_state; }
71 State state() const { return m_state; }
71 QString name() const { return m_name; }
72 QString name() const { return m_name; }
73+ Qt::ScreenOrientation orientation() const { return m_orientation; }
72 MirSurfaceItem* parentSurface() const { return m_parentSurface; }
74 MirSurfaceItem* parentSurface() const { return m_parentSurface; }
73 QList<MirSurfaceItem*> childSurfaceList();
75 QList<MirSurfaceItem*> childSurfaceList();
77+ void setOrientation(const Qt::ScreenOrientation orientation);
75 void setApplication(ApplicationInfo* item);
78 void setApplication(ApplicationInfo* item);
76 void setParentSurface(MirSurfaceItem* item);
79 void setParentSurface(MirSurfaceItem* item);
@@ -82,6 +85,7 @@ Q_SIGNALS:
82 void typeChanged(Type);
85 void typeChanged(Type);
83 void stateChanged(State);
86 void stateChanged(State);
84 void nameChanged(QString);
87 void nameChanged(QString);
88+ void orientationChanged();
85 void parentSurfaceChanged(MirSurfaceItem*);
89 void parentSurfaceChanged(MirSurfaceItem*);
86 void childSurfacesChanged();
90 void childSurfacesChanged();
@@ -110,6 +114,7 @@ private:
110 const QString m_name;
114 const QString m_name;
111 const Type m_type;
115 const Type m_type;
112 State m_state;
116 State m_state;
117+ Qt::ScreenOrientation m_orientation;
114 MirSurfaceItem* m_parentSurface;
119 MirSurfaceItem* m_parentSurface;
115 QList<MirSurfaceItem*> m_children;
120 QList<MirSurfaceItem*> m_children;