summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/direct2d
Commit message (Collapse)AuthorAgeFilesLines
* Windows/Direct2d QPA: Use nullptrFriedemann Kleint2019-01-287-37/+38
| | | | | Change-Id: I6ce01caa58de78e0eb61e243ee1e7b05cc1f5568 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* configure: refactor directx checksOswald Buddenhagen2018-12-171-1/+2
| | | | | | | | | | | | | | | properly atomize the libraries and express their dependencies, and adjust the project files accordingly. note that we don't try to use any additional paths, as all SDKs we currently support have built-in directx 11 support: - msvc2013 comes with win sdk 8.1; that is also used for win7 targets - mingw-64 5.3 (though this one is missing fxc, which is why the code path for using an external sdk for that remains) Change-Id: Ib44e389ef46567308293c2bbcad20a96e8ef70c7 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* Direct2D QPA: Fix Qt include statementsFriedemann Kleint2018-05-2315-30/+30
| | | | | | | | | | | | Change #include <QtCore/QDebug> to #include <QtCore/qdebug.h> according to the coding style. Change-Id: I34ddf9b9101cfbd5054584608de09de5b4b2f233 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Direct2D: Replace class Direct2DVersion by QVersionNumberFriedemann Kleint2018-01-041-104/+38
| | | | | Change-Id: Iad8c659a301c6d71b26964d84a67a51352712218 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* Merge remote-tracking branch 'origin/5.10' into devLiang Qi2018-01-041-1/+1
|\ | | | | | | Change-Id: I644cd82b0d952b7d139e0228bf5017f147db77e7
| * windows: Link to libversion.a with a lowercase nameMartin Storsjö2018-01-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | MinGW's headers and libraries are lowercase, and MSVC is generally run on a case-insensitive file system. Referring to libraries with a lowercase name is more compatible. This fixes cross-building using MinGW, and matches a similar change for headers in dfaa32a945. Change-Id: I728376f239a23c700416643cae98e271bbcdff32 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Merge remote-tracking branch 'origin/5.10' into devAllan Sandfeld Jensen2017-10-241-1/+2
|\| | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/platforms/windows/qwindowsmousehandler.cpp src/plugins/platforms/xcb/qxcbimage.cpp tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp tests/manual/qtabletevent/regular_widgets/main.cpp Done-with: Friedemann Kleint<Friedemann.Kleint@qt.io> Done-with: Mårten Nordheim<marten.nordheim@qt.io> Change-Id: I5b2499513a92c590ed0756f7d2e93c35a64b7f30
| * Merge remote-tracking branch 'origin/5.9' into 5.10Liang Qi2017-10-231-1/+2
| |\ | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/platforms/direct2d/direct2d.pro src/plugins/platforms/ios/qiosclipboard.mm src/plugins/platforms/windows/windows.pro Change-Id: Idffa03b3990bd642784f528821c5446b2e1008ef
| | * Windows/Direct2D QPA: Fix build with -no-accessibilityFriedemann Kleint2017-10-201-1/+3
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-63876 Change-Id: Ib9216977dd495e05d032e679c2f23ffe6a6953a6 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* | | Replace Q_NULLPTR with nullptr where possibleKevin Funk2017-09-194-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remaining uses of Q_NULLPTR are in: src/corelib/global/qcompilerdetection.h (definition and documentation of Q_NULLPTR) tests/manual/qcursor/qcursorhighdpi/main.cpp (a test executable compilable both under Qt4 and Qt5) Change-Id: If6b074d91486e9b784138f4514f5c6d072acda9a Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
* | | Replace Q_DECL_OVERRIDE with override where possibleKevin Funk2017-09-197-50/+50
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remaining uses of Q_DECL_OVERRIDE are in: src/corelib/global/qcompilerdetection.h src/corelib/global/qglobal.cpp doc/global/qt-cpp-defines.qdocconf (definition and documentation of Q_DECL_OVERRIDE) tests/manual/qcursor/qcursorhighdpi/main.cpp (a test executable compilable both under Qt4 and Qt5) Change-Id: Ib9b05d829add69e98a86238274b6a1fcb19b49ba Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
* | Merge remote-tracking branch 'origin/5.9' into devLiang Qi2017-06-191-1/+2
|\| | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/io/qprocess_unix.cpp src/corelib/io/qprocess_win.cpp src/plugins/platforms/android/qandroidplatformintegration.h src/plugins/platforms/windows/qwindowscontext.cpp src/plugins/platforms/windows/windows.pri src/tools/uic/cpp/cppwriteinitialization.cpp src/widgets/doc/src/widgets-and-layouts/gallery.qdoc Change-Id: I8d0834c77f350ea7540140c2c7f372814afc2d0f
| * Direct2D: Fix build with MinGW 7.1Friedemann Kleint2017-06-141-1/+2
| | | | | | | | | | | | | | | | | | | | | | qwindowsdirect2ddevicecontext.cpp:92:105: error: format '%x' expects argument of type 'unsigned int', but argument 4 has type 'HRESULT {aka long int}' [-Werror=format=] qWarning("%s: EndDraw failed: %#x, tag1: %lld, tag2: %lld", __FUNCTION__, hr, tag1, tag2); Change format to long and cast argument to long for extra safety (should some obscure MinGW header define another type). Change-Id: I7e6cb8ea1e5c27ef104b162ced9a696ab252fd8d Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Basic Vulkan enablersLaszlo Agocs2017-03-171-0/+2
|/ | | | | | | | | | | | | | | | | | | | | | | | | | For Android, Windows and xcb. Verified on Win10 with NVIDIA, Win10 with AMD, Android with Tegra K1, Android aarch64 with Tegra X1, and Linux aarch64 with Tegra X1 (Jetson TX1, L4T). Introduce QPA-based Vulkan library loader, core function resolver, and instance creation support. In addition to creating a new VkInstance, adopting an existing one from an external engine is supported as well. The WSI specifics are hidden in the platform plugins. Vulkan-capable windows use the new surface type VulkanSurface and are associated with a QVulkanInstance. On Windows VULKAN_SDK is picked up automatically so finding vulkan.h needs no additional manual steps once the LunarG SDK is installed. [ChangeLog][QtGui] Added support for rendering to QWindow via the Vulkan graphics API. Task-number: QTBUG-55981 Change-Id: I50fa92d313fa440e0cc73939c6d7510ca317fbc9 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* Merge remote-tracking branch 'origin/5.8' into devLiang Qi2016-12-131-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: configure qmake/Makefile.unix.macos qmake/Makefile.unix.win32 qmake/generators/win32/msvc_vcproj.cpp src/3rdparty/pcre/qt_attribution.json src/corelib/io/qsettings.cpp src/corelib/kernel/qdeadlinetimer.cpp src/platformsupport/kmsconvenience/qkmsdevice.cpp src/platformsupport/kmsconvenience/qkmsdevice_p.h src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmscreen.cpp src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/qeglfskmsegldeviceintegration.cpp src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/qeglfskmsegldevicescreen.cpp src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/qeglfskmsdevice.cpp src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/qeglfskmsscreen.h tests/manual/qstorageinfo/printvolumes.cpp tools/configure/configureapp.cpp Change-Id: Ibaabcc8e965c44926f9fb018466e8b132b8df49e
| * Register fonts with preferred names on WindowsAllan Sandfeld Jensen2016-11-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | Looks up the canonical names of enumerated fonts and register them under their preferred names if present. Also changes the logic handling registration of english aliases, so it is always done, even if it might in rare cases cause a double registration since that is safe. Task-number: QTBUG-53458 Change-Id: Ia010774b26072192b55697b717cc37442c852881 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* | Merge remote-tracking branch 'origin/5.8' into devLiang Qi2016-11-171-0/+7
|\| | | | | | | | | | | | | | | Conflicts: mkspecs/features/mac/default_post.prf mkspecs/features/uikit/default_post.prf Change-Id: I2a6f783451f2ac9eb4c1a050f605435d2dacf218
| * Direct2D QPA: Add #include directives for MinGWFriedemann Kleint2016-11-081-0/+7
| | | | | | | | | | | | | | | | D2D support has been partially added to recent versions of MinGW, which one day could make compiling the plugin possible. Change-Id: I53f91c483d3b900698f4424cb6a72f626e32e60b Reviewed-by: Louai Al-Khanji <louai.al-khanji@qt.io>
* | Direct2D QPA: Fix g++ warningsFriedemann Kleint2016-11-056-41/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | Fix warnings like: qwindowsdirect2dpaintengine.cpp:722:107: error: format '%x' expects argument of type 'unsigned int', but argument 4 has type 'HRESULT {aka long int}' [-Werror=format=] qWarning("%s: Could not convert Direct2D linear gradient brush: %#x", __FUNCTION__, hr); qwindowsdirect2dintegration.cpp:112:88: error: passing NULL to non-pointer argument 2 of 'WINBOOL GetFileVersionInfoW(LPCWSTR, DWORD, DWORD, LPVOID)' [-Werror=conversion-null] if (GetFileVersionInfo(filename, NULL, versionInfoSize, info.data())) { ^ Change-Id: Ie03abdb5f4ba47b4803c283b9a4ec10181aae76e Reviewed-by: Louai Al-Khanji <louai.al-khanji@qt.io>
* | Merge remote-tracking branch 'origin/5.8' into devLiang Qi2016-11-023-7/+10
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Blacklist tst_QMenuBar::taskQTBUG46812_doNotLeaveMenubarHighlighted() on macOS. Conflicts: mkspecs/features/mac/default_post.prf mkspecs/features/mac/sdk.prf mkspecs/features/uikit/default_post.prf mkspecs/features/uikit/sdk.prf src/angle/src/libEGL/libEGL.pro src/platformsupport/fontdatabases/fontdatabases.pro src/platformsupport/platformsupport.pro src/plugins/platforms/cocoa/qnswindowdelegate.mm src/plugins/platforms/direct2d/qwindowsdirect2dintegration.cpp src/plugins/platforms/ios/ios.pro src/plugins/platforms/ios/kernel.pro tests/auto/widgets/widgets/qmenubar/BLACKLIST tests/auto/widgets/widgets/qmenubar/tst_qmenubar.cpp Task-number: QTBUG-56853 Change-Id: If58785210feee3550892fc7768cce90e75a2416c
| * Direct2d: Add missing dependency to platformsupport's accessibilityFriedemann Kleint2016-10-281-1/+1
| | | | | | | | | | Change-Id: I620370bb5f4bbac11c1e5740c706e0cb64d9d407 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
| * Move Windows font DB and engines to QtFontDatabaseSupportGabriel de Dietrich2016-10-282-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This allows creating or extending QPA plugins to provide access to QFont and related types. It concerns both GDI and DirectWrite engines, as well as the regular and the freetype based font databases. The qt.qpa.fonts logging category has been moved together into the QWindowsFontDatabase related files to avoid depending on the qwindowscontext.h header file. Finally, QwindowsNativeImage is following pending a future refactor with similar code in qpixmap_win.cpp and the Windows XP style. Change-Id: Iddff2f3d715e3ab7695e6c2052b7596a01fd6fa8 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| * qwindowsdirect2dintegration.cpp: replace QVector with QVarLengthArrayAnton Kudryavtsev2016-10-251-1/+3
| | | | | | | | | | | | | | | | | | QVector was used as just RAII for local array. It's inefficient usage of CoW type. So use QVarLengthArray instead. Change-Id: I494ecc49af9049569a65e258581137bad3ce7dc7 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
| * port to modularized platformsupport librariesOswald Buddenhagen2016-10-152-4/+4
| | | | | | | | | | Change-Id: I20eb0e33abfd70b6a5240e7b6b0aa0425f2d2ee7 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* | Direct2d: De-virtualize destructor of QWindowsDirect2DContextFriedemann Kleint2016-10-272-2/+2
| | | | | | | | | | | | | | | | The class is not a virtual base class. Change-Id: If6a86487317d8e79e9618b4f6a46793aa95ea9ea Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Louai Al-Khanji <louai.al-khanji@qt.io>
* | Direct2D QPA plugin: Use member initializationFriedemann Kleint2016-10-276-31/+15
| | | | | | | | | | | | | | | | Use C++ 11 member initialization in value-type structs. Task-number: QTBUG-51673 Change-Id: I2e609337cfc057d1de23b3de62b9ed43a4ecec9c Reviewed-by: Louai Al-Khanji <louai.al-khanji@qt.io>
* | Direct2d: Fix some CLANG warningsFriedemann Kleint2016-10-275-79/+81
|/ | | | | | | Fix warnings about integer and double to float conversions, mostly. Change-Id: I7c0568051eabea9af9cbdaeb36da0b2affb174e1 Reviewed-by: Louai Al-Khanji <louai.al-khanji@qt.io>
* Direct2D platform plugin: Fix developer build with MSVC2015Friedemann Kleint2016-10-111-1/+1
| | | | | | | | | Fix error: qwindowsdirect2dbitmap.cpp(84): error C2220: warning treated as error - no 'object' file generated qwindowsdirect2dbitmap.cpp(84): warning C4838: conversion from 'int' to 'UINT32' requires a narrowing conversion Change-Id: I191f3300cd22715001eebc113b672ceac49c825d Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
* Support C++17 fallthrough attributeAllan Sandfeld Jensen2016-08-191-1/+1
| | | | | | | | | Replaces our mix of comments for annotating intended absence of break in switches with the C++17 attribute [[fallthrough]], or its earlier a clang extension counterpart. Change-Id: I4b2d0b9b5e4425819c7f1bf01608093c536b6d14 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Add QPlatformBackingStore::toImage() implementationsAndy Nichols2016-04-302-0/+7
| | | | | | | | | On platforms where it makes sense, add the implementation that makes returning a QImage possible. This makes it possible to grab raster windows. Change-Id: I89241728aa6f7811c56bb66cd86a64aa961d71f8 Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-04-111-7/+7
|\ | | | | | | | | | | | | | | Conflicts: src/corelib/kernel/qobject.cpp src/gui/painting/qpaintengine_raster.cpp Change-Id: I74e1779832f43d033708dcfd6b666c7b4f0111fb
| * Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-04-071-7/+7
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/network/access/qftp.cpp src/widgets/itemviews/qheaderview.cpp src/widgets/itemviews/qlistview.cpp tests/auto/network/access/qftp/tst_qftp.cpp Change-Id: I9f928f25d45d8944dd60bb583f649fc1615bc5d9
| | * Direct2D QPA: Fix build with clang-cl.Friedemann Kleint2016-04-061-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove overzealous constexpr triggering errors like: in file included from .\qwindowsdirect2dpaintengine.cpp:44: ./qwindowsdirect2dhelpers.h(58,37) : error: constexpr function never produces a constant expression [-Winvalid-constexpr] Q_DECL_CONSTEXPR inline D2D1_RECT_F to_d2d_rect_f(const QRectF &qrect) ^ ./qwindowsdirect2dhelpers.h(60,12) : note: non-constexpr function 'RectF' cannot be used in a constant expression return D2D1::RectF(qrect.x(), qrect.y(), qrect.x() + qrect.width(), qrect.y() + qrect.height()); ^ C:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\um\d2d1helper.h(160,5) : note: declared here RectF( ^ Task-number: QTBUG-50860 Change-Id: I0bb4d17b7a7db69c5cc7e286ef0b8ff104f72b2e Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
* | | Direct2D QPA: Fix build.Friedemann Kleint2016-04-062-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | Directly link against DwmApi and fix breakage introduced by refactoring QRegion. Change-Id: I45cd696de630aebb5347130560ab69530eefbcdb Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
* | | Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-03-221-5/+5
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: configure mkspecs/common/wince/qplatformdefs.h src/plugins/platforms/directfb/qdirectfbbackingstore.cpp src/plugins/platforms/xcb/qxcbbackingstore.cpp Change-Id: Ied4d31264a9afca9514b51a7eb1494c28712793c
| * | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-03-111-5/+5
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change partially reverts 1bfc7f68 about QT_HAS_BUILTIN define and undef in src/corelib/tools/qsimd_p.h. This change is also squashed with "Fall back to c++11 standard compiler flag for host builds" which is done by Peter Seiderer. Conflicts: mkspecs/features/default_post.prf src/3rdparty/sqlite/0001-Fixing-the-SQLite3-build-for-WEC2013-again.patch src/3rdparty/sqlite/sqlite3.c src/corelib/tools/qsimd_p.h src/gui/kernel/qevent.cpp src/gui/kernel/qwindowsysteminterface.cpp src/gui/kernel/qwindowsysteminterface_p.h src/plugins/bearer/blackberry/blackberry.pro src/plugins/platforms/cocoa/qcocoasystemsettings.mm src/plugins/platformthemes/gtk2/gtk2.pro src/plugins/styles/bb10style/bb10style.pro src/sql/drivers/sqlite2/qsql_sqlite2.cpp tools/configure/configureapp.cpp Task-number: QTBUG-51644 Done-with: Peter Seiderer <ps.report@gmx.net> Change-Id: I6100d6ace31b2e8d41a95f0b5d5ebf8f1fd88b44
| | * consistently put {qt,qml}_{module,plugin} at the end of project filesOswald Buddenhagen2016-03-071-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | this fixes static builds by ensuring that all dependencies are exported. Task-number: QTBUG-51071 Change-Id: Icbce502dcbcb4d4b4d922c42679f44e2cc930bf3 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
* | | QtOpenGL/plugins/platformsupport: use new QRegion::begin()/end() instead of ↵Marc Mutz2016-03-022-4/+3
|/ / | | | | | | | | | | | | | | | | | | rect() Saves e.g. ~900b and ~2900b in text size in QtOpenGL and XcbQpa libs, resp., on optimized GCC 5.3 Linux AMD64 builds. Change-Id: Id904689164ca32df41118a23747c70048d8e6604 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | QPainter: replace an inefficient QList with QVectorMarc Mutz2016-02-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | QPainterClipInfo is larger than a void*, so holding it in QLists is needlessly inefficient. Worse, the code could come to depend on the fragile property of (inefficient) QLists that references to elements therein never are invalidated. Fix by marking it movable and holding it in a QVector instead. Port from op<< to append() to reap rvalue push_back(). Change-Id: I3af17eca2443d26a795381635510b8b9a5795e5f Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* | Merge remote-tracking branch 'origin/5.6' into devLiang Qi2016-02-112-0/+6
|\| | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/io/qfilesystemwatcher_win.cpp src/corelib/plugin/plugin.pri src/plugins/platforms/cocoa/qcocoaaccessibility.mm tests/auto/corelib/tools/qlocale/tst_qlocale.cpp Change-Id: Id6824631252609a75eff8b68792e4d10095c8fc1
| * Direct2D: Spell out ~QWindowsDirect2DPaintDevice.Friedemann Kleint2016-02-042-0/+6
| | | | | | | | | | | | | | | | | | Fixes warning about deleting the incomplete type QWindowsDirect2DPaintDevicePrivate. Task-number: QTBUG-50860 Change-Id: I11edb49e6e3996963913155e307fd5f3944bffd2 Reviewed-by: Louai Al-Khanji <louai.al-khanji@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.6' into devLiang Qi2016-01-212-4/+3
|\| | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/io/qiodevice_p.h src/corelib/kernel/qvariant_p.h src/corelib/tools/qsimd.cpp src/gui/kernel/qguiapplication.cpp tests/auto/network/socket/qtcpsocket/tst_qtcpsocket.cpp Change-Id: I742a093cbb231b282b43e463ec67173e0d29f57a
| * Windows/Direct2D QPA plugins: Fix overrides.Friedemann Kleint2016-01-142-4/+3
| | | | | | | | | | | | | | Fix warnings found by clang. Change-Id: Ia8e7a271e9d33011eded1e63e61dbcaeaf692600 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
* | Updated license headersJani Heikkinen2016-01-1522-308/+440
| | | | | | | | | | | | | | | | | | | | | | From Qt 5.7 -> LGPL v2.1 isn't an option anymore, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new LGPL header instead of LGPL21 one (in those files which will be under LGPL v3) Change-Id: I046ec3e47b1876cd7b4b0353a576b352e3a946d9 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | Use Q_UNLIKELY for every qFatal()/qCritical()Marc Mutz2015-11-291-1/+1
|/ | | | | | | | | | | | | | | | | | | | | If, after checking a condition, we issue a qFatal() or a qCritical(), by definition that check is unlikely to be true. Tell the compiler so it can move the error handling code out of the normal code path to increase the effective icache size. Moved conditional code around where possible so that we could always use Q_UNLIKELY, instead of having to revert to Q_LIKELY here and there. In some cases, simplified the expressions newly wrapped in Q_UNLIKELY as a drive-by. Change-Id: I67537d62b04bc6977d69254690c5ebbdf98bfd6d Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
* Direct2D: Fix build.Friedemann Kleint2015-11-191-1/+1
| | | | | | | | Fix the include path of the event dispatcher which changed after 08a4b7f74507be7aa9dc09a9234d3bc83d4ed908. Change-Id: Ie679b189bd65dc3388ba0d28d01036e3d05683e7 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
* Windows/Direct2D: Handle screen changes after window creation.Friedemann Kleint2015-11-132-7/+8
| | | | | | | | | | | | | | | | | Call QWindowSystemInterface::handleWindowScreenChanged() in QWindowsIntegration::createPlatformWindow() should the effective screen be different from the initial screen due to the geometry. In order to avoid code duplication in the Direct2D plugin, fold the helper method createWindowData() into QWindowsIntegration::createPlatformWindow() and introduce a new virtual helper to create the actual platform window for QWindowsDirect2DIntegration to hook in. Task-number: QTBUG-48379 Change-Id: I49c7a50a12245691414ab49bffe802239a87d2d6 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
* Enable non-integer device pixel ratioMorten Johan Sørvig2015-07-301-0/+3
| | | | | | | | | | | | | | | | | | | | Work around QPaintDevice::metric's int return type by adding a new metric that returns a scaled devicePixelRatio. Choose a scale factor that gives us more than enough range. The QPaintDevice::devicePixelRatio() convenience accessor is public API and can unfortunately not be changed to return a qreal. Add devicePixelRatioF() which returns the (unscaled) devicePixelRatio. Change all call sites of QPaintDevice::devicePixelRatio() to use QPainDevice::devicePixelRatioF(). Task-number: QTBUG-46615 Change-Id: I97ec4000fe379b7ff5e1624a871ae2512790aad9 Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com> Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* Direct2D: Fix MSVC2015 warnings.Friedemann Kleint2015-05-232-12/+12
| | | | | | | | | | | | | qwindowsdirect2dpaintengine.cpp(365): warning C4838: conversion from 'const qreal' to 'FLOAT' requires a narrowing conversion qwindowsdirect2dpaintengine.cpp(928): warning C4838: conversion from 'const qreal' to 'FLOAT' requires a narrowing conversion qwindowsdirect2dpaintengine.cpp(928): warning C4838: conversion from 'int' to 'UINT32' requires a narrowing conversion qwindowsdirect2dpaintengine.cpp(1398): warning C4838: conversion from 'qreal' to 'FLOAT' requires a narrowing conversion qwindowsdirect2dpaintengine.cpp(1426): warning C4838: conversion from 'double' to 'FLOAT' requires a narrowing conversion qwindowsdirect2dbitmap.cpp(78): warning C4838: conversion from 'int' to 'UINT32' requires a narrowing conversion qwindowsdirect2dwindow.cpp(166): warning C4838: conversion from 'double' to 'BYTE' requires a narrowing conversion Change-Id: I6992260ed2696fa4c47c1c0dd666f448f115879a Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
* QPA plugins: Use _iid macros instead of strings in Q_PLUGIN_METADATA.Friedemann Kleint2015-05-131-1/+1
| | | | | | | | | This makes it easier to change the version numbers by changing the macros in QtGui. Task-number: QTBUG-46009 Change-Id: I94c9591ec6f7c9173a698df9e1fe8fd6a904caf4 Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>