Changeset View
Changeset View
Standalone View
Standalone View
kcm/src/scalingconfig.h
Show All 24 Lines | |||||
25 | #include <KScreen/Types> | 25 | #include <KScreen/Types> | ||
26 | 26 | | |||
27 | #include "ui_scaling.h" | 27 | #include "ui_scaling.h" | ||
28 | 28 | | |||
29 | class ScalingConfig : public QDialog | 29 | class ScalingConfig : public QDialog | ||
30 | { | 30 | { | ||
31 | Q_OBJECT | 31 | Q_OBJECT | ||
32 | public: | 32 | public: | ||
33 | explicit ScalingConfig(const KScreen::OutputList &outputList, QWidget* parent = 0); | 33 | explicit ScalingConfig(const KScreen::OutputPtr &output, QWidget* parent = 0); | ||
34 | virtual ~ScalingConfig(); | 34 | virtual ~ScalingConfig(); | ||
35 | 35 | | |||
36 | protected: | 36 | protected: | ||
37 | void accept() Q_DECL_OVERRIDE; | 37 | void accept() Q_DECL_OVERRIDE; | ||
38 | private: | 38 | private: | ||
39 | void load(); | 39 | void load(); | ||
40 | qreal scaleFactor() const; | 40 | qreal scaleFactor() const; | ||
41 | int scaleDPI() const; | 41 | int scaleDPI() const; | ||
42 | Ui::Scaling ui; | 42 | Ui::Scaling ui; | ||
43 | qreal m_initialScalingFactor = 1.0; | 43 | qreal m_initialScalingFactor = 1.0; | ||
44 | KScreen::OutputList m_outputList; | 44 | QMap<QString, qreal> m_screenFactors; | ||
45 | KScreen::OutputPtr m_output; | ||||
45 | }; | 46 | }; | ||
46 | 47 | | |||
47 | #endif // SCALINGCONFIG_H | 48 | #endif // SCALINGCONFIG_H |