WinRT: use qEnvironmentVariableIntValue()
It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: I73d548ad4e25424fc41722961f527e63632a7b56 Reviewed-by: Andrew Knight <andrew.knight@digia.com> Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
This commit is contained in:
parent
1dce3b7d11
commit
dcb48c6dc6
@ -178,7 +178,7 @@ QWinRTTheme::QWinRTTheme()
|
||||
bool QWinRTTheme::usePlatformNativeDialog(DialogType type) const
|
||||
{
|
||||
static bool useNativeDialogs = qEnvironmentVariableIsSet("QT_USE_WINRT_NATIVE_DIALOGS")
|
||||
? qgetenv("QT_USE_WINRT_NATIVE_DIALOGS").toInt() : true;
|
||||
? qEnvironmentVariableIntValue("QT_USE_WINRT_NATIVE_DIALOGS") : true;
|
||||
|
||||
if (type == FileDialog || type == MessageDialog)
|
||||
return useNativeDialogs;
|
||||
|
Loading…
Reference in New Issue
Block a user