Tighten Q_OS_WINRT ifdefs in qfunctions_winrt.h
This allows the convenience macros to be used on desktop Windows 8 when interacting with Windows Runtime types. Change-Id: I09c6b18a6ee9711371ef7dc23fb1d3354198db1c Reviewed-by: Maurice Kalinowski <maurice.kalinowski@digia.com>
This commit is contained in:
parent
4a2e297b4f
commit
67c83f329e
@ -44,8 +44,6 @@
|
||||
|
||||
#include <QtCore/qglobal.h>
|
||||
|
||||
#ifdef Q_OS_WINRT
|
||||
|
||||
#include <QtCore/QThread>
|
||||
#include <QtCore/QAbstractEventDispatcher>
|
||||
#include <QtCore/qt_windows.h>
|
||||
@ -57,6 +55,8 @@ QT_BEGIN_NAMESPACE
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#ifdef Q_OS_WINRT
|
||||
|
||||
// Environment ------------------------------------------------------
|
||||
errno_t qt_winrt_getenv_s(size_t*, char*, size_t, const char*);
|
||||
errno_t qt_winrt__putenv_s(const char*, const char*);
|
||||
@ -122,6 +122,8 @@ generate_inline_return_func2(_putenv_s, errno_t, const char *, const char *)
|
||||
generate_inline_return_func0(tzset, void)
|
||||
generate_inline_return_func0(_tzset, void)
|
||||
|
||||
#endif // Q_OS_WINRT
|
||||
|
||||
// Convenience macros for handling HRESULT values
|
||||
#define RETURN_IF_FAILED(msg, ret) \
|
||||
if (FAILED(hr)) { \
|
||||
@ -211,5 +213,4 @@ static inline HRESULT await(const Microsoft::WRL::ComPtr<T> &asyncOp, U *results
|
||||
|
||||
} // QWinRTFunctions
|
||||
|
||||
#endif // Q_OS_WINRT
|
||||
#endif // QFUNCTIONS_WINRT_H
|
||||
|
Loading…
Reference in New Issue
Block a user