summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/xcb/qxcbscreen.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/platforms/xcb/qxcbscreen.h')
-rw-r--r--src/plugins/platforms/xcb/qxcbscreen.h20
1 files changed, 15 insertions, 5 deletions
diff --git a/src/plugins/platforms/xcb/qxcbscreen.h b/src/plugins/platforms/xcb/qxcbscreen.h
index 51c92a40ae..c68c290791 100644
--- a/src/plugins/platforms/xcb/qxcbscreen.h
+++ b/src/plugins/platforms/xcb/qxcbscreen.h
@@ -68,20 +68,33 @@ public:
xcb_window_t root() const { return m_screen->root; }
QXcbScreen *screenAt(const QPoint &pos) const;
+ QList<QPlatformScreen *> screens() const { return m_screens; }
+ void setScreens(QList<QPlatformScreen *> sl) { m_screens = sl; }
+ void removeScreen(QPlatformScreen *s) { m_screens.removeOne(s); }
+ void addScreen(QPlatformScreen *s);
+
QXcbXSettings *xSettings() const;
bool compositingActive() const;
+ QRect workArea() const { return m_workArea; }
+ void updateWorkArea();
+
void handleXFixesSelectionNotify(xcb_xfixes_selection_notify_event_t *notify_event);
void subscribeToXFixesSelectionNotify();
private:
+ QRect getWorkArea() const;
+
xcb_screen_t *m_screen;
int m_number;
+ QList<QPlatformScreen *> m_screens;
QXcbXSettings *m_xSettings;
xcb_atom_t m_net_wm_cm_atom;
bool m_compositingActive;
+
+ QRect m_workArea;
};
class Q_XCB_EXPORT QXcbScreen : public QXcbObject, public QPlatformScreen
@@ -110,10 +123,7 @@ public:
QPlatformCursor *cursor() const Q_DECL_OVERRIDE;
qreal refreshRate() const Q_DECL_OVERRIDE { return m_refreshRate; }
Qt::ScreenOrientation orientation() const Q_DECL_OVERRIDE { return m_orientation; }
- QList<QPlatformScreen *> virtualSiblings() const Q_DECL_OVERRIDE { return m_siblings; }
- void setVirtualSiblings(QList<QPlatformScreen *> sl) { m_siblings = sl; }
- void removeVirtualSibling(QPlatformScreen *s) { m_siblings.removeOne(s); }
- void addVirtualSibling(QPlatformScreen *s) { ((QXcbScreen *) s)->isPrimary() ? m_siblings.prepend(s) : m_siblings.append(s); }
+ QList<QPlatformScreen *> virtualSiblings() const Q_DECL_OVERRIDE { return m_virtualDesktop->screens(); }
QXcbVirtualDesktop *virtualDesktop() const { return m_virtualDesktop; }
void setPrimary(bool primary) { m_primary = primary; }
@@ -139,6 +149,7 @@ public:
void handleScreenChange(xcb_randr_screen_change_notify_event_t *change_event);
void updateGeometry(const QRect &geom, uint8_t rotation);
void updateGeometry(xcb_timestamp_t timestamp = XCB_TIME_CURRENT_TIME);
+ void updateAvailableGeometry();
void updateRefreshRate(xcb_randr_mode_t mode);
void readXResources();
@@ -171,7 +182,6 @@ private:
QRect m_availableGeometry;
QSize m_virtualSize;
QSizeF m_virtualSizeMillimeters;
- QList<QPlatformScreen *> m_siblings;
Qt::ScreenOrientation m_orientation;
QString m_windowManagerName;
bool m_syncRequestSupported;