diff options
author | Maurice Kalinowski <maurice.kalinowski@nokia.com> | 2009-05-04 12:12:40 (GMT) |
---|---|---|
committer | Maurice Kalinowski <maurice.kalinowski@nokia.com> | 2009-05-04 12:13:58 (GMT) |
commit | f68f352dec04d796916dd8c4f5f60e8f62e4edf6 (patch) | |
tree | c50f7f1230db297d5e1ac3158fd096e4425cccd4 /src | |
parent | 5dec3808ed6724a096e5dfc579d37e8528de75e0 (diff) | |
download | Qt-f68f352dec04d796916dd8c4f5f60e8f62e4edf6.zip Qt-f68f352dec04d796916dd8c4f5f60e8f62e4edf6.tar.gz Qt-f68f352dec04d796916dd8c4f5f60e8f62e4edf6.tar.bz2 |
prefer macro over stub
- Windows Mobile does the same, thus we will not have double definitions or such
- COINIT_MULTITHREADED is the default, meaning that 0 usually expands to it. Just be on the safe side and be more precise.
Task-number: 237029
Reviewed-by: joerg
Diffstat (limited to 'src')
-rw-r--r-- | src/corelib/kernel/qfunctions_wince.cpp | 5 | ||||
-rw-r--r-- | src/corelib/kernel/qfunctions_wince.h | 5 |
2 files changed, 3 insertions, 7 deletions
diff --git a/src/corelib/kernel/qfunctions_wince.cpp b/src/corelib/kernel/qfunctions_wince.cpp index 1c929c7..e0f7687 100644 --- a/src/corelib/kernel/qfunctions_wince.cpp +++ b/src/corelib/kernel/qfunctions_wince.cpp @@ -285,11 +285,6 @@ int qt_wince_SetErrorMode(int newValue) return result; } -HRESULT qt_wince_CoInitialize(void* reserved) -{ - return CoInitializeEx(reserved, 0); -} - bool qt_wince__chmod(const char *file, int mode) { return _wchmod( reinterpret_cast<const wchar_t *> (QString::fromLatin1(file).utf16()), mode); diff --git a/src/corelib/kernel/qfunctions_wince.h b/src/corelib/kernel/qfunctions_wince.h index 123bd23..5f08bb3 100644 --- a/src/corelib/kernel/qfunctions_wince.h +++ b/src/corelib/kernel/qfunctions_wince.h @@ -199,7 +199,9 @@ int qt_wince__fstat( int handle, struct stat *buffer); #define SEM_FAILCRITICALERRORS 0x0001 #define SEM_NOOPENFILEERRORBOX 0x0002 int qt_wince_SetErrorMode(int); -HRESULT qt_wince_CoInitialize(void* reserved); +#ifndef CoInitialize +#define CoInitialize(x) CoInitializeEx(x, COINIT_MULTITHREADED) +#endif bool qt_wince__chmod(const char *file, int mode); bool qt_wince__wchmod(const WCHAR *file, int mode); @@ -376,7 +378,6 @@ typedef DWORD OLE_COLOR; #define _rename(a,b) qt_wince__rename(a,b) #define _remove(a) qt_wince__remove(a) #define SetErrorMode(a) qt_wince_SetErrorMode(a) -#define CoInitialize(a) qt_wince_CoInitialize(a) #define _chmod(a,b) qt_wince__chmod(a,b) #define _wchmod(a,b) qt_wince__wchmod(a,b) #define CreateFileA(a,b,c,d,e,f,g) qt_wince_CreateFileA(a,b,c,d,e,f,g) |