mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-02-03 10:25:02 +00:00
Use qEnvironmentVariableIsEmpty
Instead of qgetenv("QT_AUTO_SCREEN_SCALE_FACTOR").isEmpty(). It's faster (don't allocate memory) and don't throw exceptions.
This commit is contained in:
parent
b87ca60c5a
commit
2114817890
@ -338,7 +338,7 @@ void showSplashScreen()
|
|||||||
#if defined(Q_OS_UNIX)
|
#if defined(Q_OS_UNIX)
|
||||||
void setupDpi()
|
void setupDpi()
|
||||||
{
|
{
|
||||||
if (qgetenv("QT_AUTO_SCREEN_SCALE_FACTOR").isEmpty())
|
if (qEnvironmentVariableIsEmpty("QT_AUTO_SCREEN_SCALE_FACTOR"))
|
||||||
qputenv("QT_AUTO_SCREEN_SCALE_FACTOR", "1");
|
qputenv("QT_AUTO_SCREEN_SCALE_FACTOR", "1");
|
||||||
}
|
}
|
||||||
#endif // Q_OS_UNIX
|
#endif // Q_OS_UNIX
|
||||||
|
Loading…
x
Reference in New Issue
Block a user