diff options
author | Frederik Gladhorn <frederik.gladhorn@digia.com> | 2013-06-27 13:06:38 +0200 |
---|---|---|
committer | Frederik Gladhorn <frederik.gladhorn@digia.com> | 2013-06-27 13:06:38 +0200 |
commit | 572200989b224ad68e7b8ae4c0aecceb6ca871a2 (patch) | |
tree | 5591e8e6c17df64674aa79227ad6b70374c169ff /src/gui | |
parent | 7ed024226faa9c53c6bad96fb6c9f38a22d25751 (diff) | |
parent | 241eca33ed45f112feed18c6256c31e606f47796 (diff) |
Merge remote-tracking branch 'origin/stable' into dev
Conflicts:
configure
mkspecs/features/create_cmake.prf
Change-Id: I94aea83b83833395d5db399209e0e51b92ef23b5
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/Qt5GuiConfigExtras.cmake.in | 7 | ||||
-rw-r--r-- | src/gui/kernel/qguiapplication.cpp | 13 |
2 files changed, 15 insertions, 5 deletions
diff --git a/src/gui/Qt5GuiConfigExtras.cmake.in b/src/gui/Qt5GuiConfigExtras.cmake.in index 83e77280d5..6ad1d679e1 100644 --- a/src/gui/Qt5GuiConfigExtras.cmake.in +++ b/src/gui/Qt5GuiConfigExtras.cmake.in @@ -16,11 +16,12 @@ set(Qt5Gui_OPENGL_INCLUDE_DIRS ${Qt5Gui_EGL_INCLUDE_DIRS}) macro(_populate_qt5gui_gl_target_properties TargetName Configuration LIB_LOCATION IMPLIB_LOCATION) set_property(TARGET Qt5::${TargetName} APPEND PROPERTY IMPORTED_CONFIGURATIONS ${Configuration}) -!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE) - set(imported_location \"${_qt5Gui_install_prefix}/$${CMAKE_LIB_DIR}${LIB_LOCATION}\") +!!IF isEmpty(CMAKE_DLL_DIR_IS_ABSOLUTE) + set(imported_location \"${_qt5Gui_install_prefix}/$${CMAKE_DLL_DIR}${LIB_LOCATION}\") !!ELSE - set(imported_location \"$${CMAKE_LIB_DIR}${LIB_LOCATION}\") + set(imported_location \"$${CMAKE_DLL_DIR}${LIB_LOCATION}\") !!ENDIF + !!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE) set(imported_implib \"${_qt5Gui_install_prefix}/$${CMAKE_LIB_DIR}${IMPLIB_LOCATION}\") !!ELSE diff --git a/src/gui/kernel/qguiapplication.cpp b/src/gui/kernel/qguiapplication.cpp index 77c9978a9e..89664447c4 100644 --- a/src/gui/kernel/qguiapplication.cpp +++ b/src/gui/kernel/qguiapplication.cpp @@ -94,9 +94,12 @@ #include <QtGui/QClipboard> #endif -#ifdef Q_OS_MAC +#if defined(Q_OS_MAC) # include "private/qcore_mac_p.h" -#endif +#elif defined(Q_OS_WIN) && !defined(Q_OS_WINCE) +# include <QtCore/qt_windows.h> +# include <QtCore/QLibraryInfo> +#endif // Q_OS_WIN && !Q_OS_WINCE QT_BEGIN_NAMESPACE @@ -789,6 +792,12 @@ static void init_platform(const QString &pluginArgument, const QString &platform fatalMessage += QStringLiteral("Available platforms are: %1\n").arg( keys.join(QStringLiteral(", "))); fatalMessage += QStringLiteral("GUI applications require a platform plugin. Terminating."); +#if defined(Q_OS_WIN) && !defined(Q_OS_WINCE) + // Windows: Display message box unless it is a console application + // or debug build showing an assert box. + if (!QLibraryInfo::isDebugBuild() && !GetConsoleWindow()) + MessageBox(0, (LPCTSTR)fatalMessage.utf16(), (LPCTSTR)(QCoreApplication::applicationName().utf16()), MB_OK | MB_ICONERROR); +#endif // Q_OS_WIN && !Q_OS_WINCE qFatal("%s", qPrintable(fatalMessage)); return; } |