diff options
author | Joerg Bornemann <joerg.bornemann@nokia.com> | 2010-02-22 11:53:50 (GMT) |
---|---|---|
committer | Joerg Bornemann <joerg.bornemann@nokia.com> | 2010-02-22 12:22:46 (GMT) |
commit | bab18de3932a802568d6d9e0cea9e76f02e6bf5d (patch) | |
tree | 328d8014247f483022fb36bec26cbc5efa9195fe /src/gui/kernel/qapplication_win.cpp | |
parent | 561f2a3bf1ec74df87c3cd7c2641d34ce321c842 (diff) | |
download | Qt-bab18de3932a802568d6d9e0cea9e76f02e6bf5d.zip Qt-bab18de3932a802568d6d9e0cea9e76f02e6bf5d.tar.gz Qt-bab18de3932a802568d6d9e0cea9e76f02e6bf5d.tar.bz2 |
fix crash on Windows CE on WM_SETTINGCHANGE
On Windows CE, lParam parameter is a constant, not a char pointer.
The only valid value is INI_INTL.
Task-number: QTBUG-7943
Reviewed-by: ninerider
Diffstat (limited to 'src/gui/kernel/qapplication_win.cpp')
-rw-r--r-- | src/gui/kernel/qapplication_win.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gui/kernel/qapplication_win.cpp b/src/gui/kernel/qapplication_win.cpp index 0a4869b..aac834d 100644 --- a/src/gui/kernel/qapplication_win.cpp +++ b/src/gui/kernel/qapplication_win.cpp @@ -1905,8 +1905,13 @@ LRESULT CALLBACK QtWndProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam break; if (!msg.wParam) { +#ifdef Q_WS_WINCE + // On Windows CE, lParam parameter is a constant, not a char pointer. + if (msg.lParam == INI_INTL) { +#else QString area = QString::fromWCharArray((wchar_t*)msg.lParam); if (area == QLatin1String("intl")) { +#endif QLocalePrivate::updateSystemPrivate(); if (!widget->testAttribute(Qt::WA_SetLocale)) widget->dptr()->setLocale_helper(QLocale(), true); |