1 /* 2 * SPDX-FileCopyrightText: 2012, 2013 Daniel Vrátil <dvratil@redhat.com> 3 * 4 * SPDX-License-Identifier: LGPL-2.1-or-later 5 */ 6 #pragma once 7 8 #include "types.h" 9 10 #include <QObject> 11 #include <QSize> 12 13 class XRandRConfig; 14 namespace KScreen 15 { 16 class Screen; 17 class Config; 18 } 19 20 class XRandRScreen : public QObject 21 { 22 Q_OBJECT 23 24 public: 25 explicit XRandRScreen(XRandRConfig *config = nullptr); 26 ~XRandRScreen() override; 27 28 KScreen::ScreenPtr toKScreenScreen() const; 29 void updateKScreenScreen(KScreen::ScreenPtr &screen) const; 30 31 void update(); 32 void update(const QSize &size); 33 QSize currentSize(); 34 35 private: 36 int m_id; 37 QSize m_minSize; 38 QSize m_maxSize; 39 QSize m_currentSize; 40 }; 41