qhighdpiscaling_p.h does not compile with disabled deprecations

This commit is contained in:
Uwe Rathmann 2020-03-12 09:54:54 +01:00
parent b2537351ad
commit 32b638a2eb
2 changed files with 15 additions and 9 deletions

View File

@ -5,7 +5,6 @@
#include <qscreen.h> #include <qscreen.h>
QSK_QT_PRIVATE_BEGIN QSK_QT_PRIVATE_BEGIN
#include <private/qhighdpiscaling_p.h>
#include <private/qguiapplication_p.h> #include <private/qguiapplication_p.h>
QSK_QT_PRIVATE_END QSK_QT_PRIVATE_END
@ -147,13 +146,6 @@ qreal qskDpiScaled( qreal value )
return value * factor; return value * factor;
} }
qreal qskGlobalScaleFactor()
{
// The value of QT_SCALE_FACTOR
const QScreen* noScreen = nullptr;
return QHighDpiScaling::factor( noScreen );
}
bool qskHasPlatformWindowManagement() bool qskHasPlatformWindowManagement()
{ {
if ( auto platform = QGuiApplicationPrivate::platformIntegration() ) if ( auto platform = QGuiApplicationPrivate::platformIntegration() )
@ -169,3 +161,18 @@ QRect qskPlatformScreenGeometry( const QScreen* screen )
return screen->handle()->geometry(); return screen->handle()->geometry();
} }
#if 0
QSK_QT_PRIVATE_BEGIN
#include <private/qhighdpiscaling_p.h>
QSK_QT_PRIVATE_END
qreal qskGlobalScaleFactor()
{
// The value of QT_SCALE_FACTOR
const QScreen* noScreen = nullptr;
return QHighDpiScaling::factor( noScreen );
}
#endif

View File

@ -14,7 +14,6 @@
class QScreen; class QScreen;
QSK_EXPORT qreal qskDpiScaled( qreal value ); QSK_EXPORT qreal qskDpiScaled( qreal value );
QSK_EXPORT qreal qskGlobalScaleFactor();
QSK_EXPORT bool qskHasPlatformWindowManagement(); QSK_EXPORT bool qskHasPlatformWindowManagement();
QSK_EXPORT QRect qskPlatformScreenGeometry( const QScreen* ); QSK_EXPORT QRect qskPlatformScreenGeometry( const QScreen* );