Commit Graph

40484 Commits

Author SHA1 Message Date
Friedemann Kleint
eea6c920c9 Blacklist tst_qwindow::spuriousMouseMove() on Windows
The test is failing in 5.13 for unknown reasons.

Task-number: QTBUG-72296
Task-number: QTBUG-72344
Change-Id: I24c1ad1b6def3096de99caeeebeee6e204cc75ca
Reviewed-by: André de la Rocha <andre.rocha@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-05-20 16:43:23 +02:00
Tobias Hunger
e9085f4162 CMake: pro2cmake.py: Add target_link_libraries to examples
Change-Id: Ic7054f0c88e228496b7f4855bffa5620ed717f9b
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-05-09 13:14:45 +00:00
Tobias Hunger
35ed41e547 CMake: pro2cmake.py: Generate find_package information into examples
Change-Id: I6dab13ebea4386019f14be5f29a143d194268aac
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-05-09 13:14:37 +00:00
Liang Qi
591116490c Merge "Merge remote-tracking branch 'origin/5.12' into 5.13" into refs/staging/5.13 2019-05-09 13:06:22 +00:00
Qt Forward Merge Bot
e56d3b03ed Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	src/corelib/tools/qlocale_data_p.h
        (Regenerated by running the scripts in util/local_database/)
	src/gui/opengl/qopengltextureuploader.cpp

Done-With: Edward Welbourne <edward.welbourne@qt.io>
Done-With: Allan Sandfeld Jensen <allan.jensen@qt.io>
Change-Id: I12df7f066ed0a25eb109f61c4b8d8dea63b683e2
2019-05-09 13:06:11 +00:00
Laszlo Agocs
64a2dc3962 Add missing backslash to kmsconvenience.pro
Change-Id: I3519447af657bdbb7304aca272de416104dca0f9
Fixes: QTBUG-75730
Reviewed-by: Johan Helsing <johan.helsing@qt.io>
2019-05-09 12:55:06 +00:00
Alexandru Croitor
bc4687f5bb Keep "special case" modifications when regenerating project files
The pro2cmake.py file is now smarter, and can reapply "special case"
modifications after regenerating a CMakeLists.txt file.

This substantially lowers the maintenance burden when regenerating
many files at once.

See the special_case_helper.py file for details on how it works.

Make sure to commit the generated .prev_CMakeLists.txt file alongside
your CMakeLists.txt changes.

To disable the preservation behavior, you can pass -s or
--skip-special-case-preservation to the script.

To keep around temporary files that are created during this process,
you can pass -k or --keep-temporary-files.

To get more debug output, pass --debug-special-case-preservation.

Fixes: QTBUG-75619
Change-Id: I6d8ba52ac5feb5020f31d47841203104c2a061d8
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2019-05-09 11:29:54 +00:00
Tobias Hunger
862ebbf7ea CMake: scripts: Extract code to write find_package lines
Extract code to write find_package lines from configurejson2cmake.py
and move this over into helper.py.

Change-Id: Iefd313b2a56cb78a99a7f3151c3f6c6284482f79
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-05-09 11:29:35 +00:00
Tobias Hunger
80e0c615a9 CMake: pro2cmake.py: Separate library extraction logic from writing out data
Separate the logic to find all used libraries from the code that writes out
the link_library information into the CMakeLists(.gen)?.txt files.

This patch will remove some "PUBLIC_LIBRARIES Qt::Core" from generated files.
This is due to us handling some Qt libraries in special ways in some of our
add_qt_* helpers. These special libraries were added to the LIBRARIES section,
but actually they should be added to the PUBLIC_LIBRARIES section instead. Do
so now, so that the newly generated files do not break things again.

Change-Id: I588781087a8aecc4d879e949735671d8085f0698
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-05-09 11:29:25 +00:00
Joerg Bornemann
a12b6e7bf6 Fix CMake file generation for debug libs on macOS
CMAKE_QT_STEM already contains the _debug suffix.
Do not add it again.

This amends commit bb8a3dfc.

Fixes: QTBUG-75520
Change-Id: I6c311f0913ea83fcf299a21a0ee1f28c3861371f
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-05-09 07:50:32 +00:00
Edward Welbourne
17c44479aa Update CLDR version in attribution
This is a follow-up to 43abe86e.

Change-Id: I2442304c9c79bcb1932fb173b8d993a242d79f4b
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
2019-05-09 07:40:06 +00:00
Tobias Hunger
c4dd1a8fe3 CMake: pro2cmake.py: Extract writing lists into cmake files
Extract the actual functionality to write a list of "things" below
headers and/or cmake parameter and followed by a footer.

Reuse this functionality everywhere we write a list of things.

Change-Id: Ia7647be465b4788a2b1e6a5dbede1ca868f24ae2
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-05-09 07:38:17 +00:00
Tobias Hunger
ee3d9a8b67 CMake: scripts: Fix mypy issues
Change-Id: I706740be79eccd6bf08213fdaf747dde08cd053a
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-05-09 07:37:58 +00:00
Tobias Hunger
5608bf3cba CMake: pro2cmake.py: Add basic support for examples
Examples need to be built stand-alone and as part of Qt, so they
need a special CMakeLists.txt file that supports both use-cases.

Add an --is-example switch to pro2cmake to make it generate these special
CMakeLists.txt files.

This is basic support only and is currently still missing the necessary
find_package calls.

Change-Id: Ie770287350fb8a41e872cb0ea607923caa33073d
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-05-09 07:37:42 +00:00
Eirik Aavitsland
3d8ed3ba96 Fix: style sheet styling of background of triangular QTabWidget tabs
The triangular tab shape is not reproducible with setting style border
options, so it should be painted with the usual code path, also when a
custom background has been set.

Fixes: QTBUG-72096
Change-Id: I7bc1c0579386b8ea7266ce6456534c2519d9addf
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
2019-05-09 06:47:30 +00:00
Friedemann Kleint
fa890c4686 Windows QPA: Improve debug messages
Include screen and MINMAXINFO values in the message about not being able to
set the geometry.

Suppress output of some window finding functions unless verbose.

Change-Id: Iaaae59ecb302438b3444735067d018c77d2af162
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-05-09 06:13:27 +00:00
Martin Storsjö
827b7afba7 ANGLE: Backport fix for compilation on mingw/64bit with clang
This backports the following upstream fix from angle:
63cc351fba

Change-Id: Id80dba62c69f3505eb836f758367b4bf054b1fd5
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-05-08 21:21:41 +00:00
Sergio Martins
9444416a46 Define Q_OS_WINDOWS, make it an alias to Q_OS_WIN
As seen in several occasions, both in user code and in Qt proper,
people make these mistakes. What makes it harder to spot is that it doesn't
look like a typo, and feels natural (natural as Q_OS_LINUX instead of Q_OS_LIN feels).

There's been a P1 in qtdeclarative/ and currently there's a Q_OS_WINDOWS usage
in qtwebengine.

This is a recurring problem, no matter how much people test and review
these errors will happen, so the alias is justified.

Change-Id: If6943b52e17f0c8b238c36bb1f7834802123f12a
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2019-05-08 17:22:01 +00:00
Konstantin Shegunov
c6bee8e4b2 Fix integer overflows in QDeadlineTimer
If the deadline is far in the future, the conversions to nanoseconds
or internal arithmetic may overflow and give an invalid object, thus
the deadline may end up in the past. Added a test to the testlib
selftest for sleep.

[ChangeLog][QtCore][QDeadlineTimer] Fixed integer overflows
leading to immediate timeouts.

Task-number: QTBUG-69750
Change-Id: I9814eccdf9f9b3add9ca66ec3e27e10cd5ad54a8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2019-05-08 17:19:44 +00:00
Joerg Bornemann
2a79af6b5c Doc: Document the c++2a CONFIG value
Change-Id: Ia4d84ac141b6fb27b244dfb8272b8039e337a9e4
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
2019-05-08 13:42:28 +00:00
Mårten Nordheim
8adcfa8b24 WinRT: Fix crash in native socket engine during close
Make sure "this" still exists when we're done sending the
readNotification.

The crash manifested itself when connecting to certain websites as they
would reply with status 403, then close the connection. On our end we
would then handle this "remote host closed" followed by handling the
data we received. The http code handles the data successfully and sees
we are done and there is nothing more to do, so it closes the
connection. Which leads to closing QAbstractSocket, which closes
native socket again and then deletes it.

Fixes: QTBUG-75620
Change-Id: I233c67f359aa8234f1a2c4ea9463108b08c9165f
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-05-08 13:26:03 +00:00
Friedemann Kleint
a1516c3b93 Windows: Add debug output for message WM_DPICHANGED
Add it to the name lookup and add verbose formatting
to the debug operator.

Task-number: QTBUG-73014
Change-Id: I31ee31bc28ef563fdbc0adedcea03546ced5faad
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-05-08 13:25:59 +00:00
Tobias Hunger
5c98110fca CMake: Fix up after WrapFreetype introduction
Change-Id: I05ca6f8b055f470101ff0dcd1720a349a87e4ba9
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-05-08 12:49:55 +00:00
Christian Ehrlicher
69f6cab0af Doc: replace even more null/0/nullptr with \nullptr macro
Try to replace all wordings like '.. to 0' with '.. to \nullptr'. Also
checked for 'null pointer' and similar.

Change-Id: I73341f59ba51e0798e816a8b1a532c7c7374b74a
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2019-05-08 12:48:32 +00:00
Dmitry Kazakov
a5725561da Fetch stylus button remapping from WinTab driver
The user can remap the stylus buttons using tablet driver settings.
This information is available to the application via CSR_SYSBTNMAP
WinTab feature. We should fetch this information every time the
stylus gets into proximity, because the user can change these settings
on the fly.

Change-Id: Idc839905c3485179d782814f78fa862fd4a99127
Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2019-05-08 12:42:32 +00:00
Eirik Aavitsland
95fa35fc72 Fix possible endless loop when stroking curves
The bezier shifting algorithm compared coordinates exactly, and so
could end up in an endless loop when values were at the edge of the
number resolution. Fix by using fuzzy comparison instead.

Fixes: QTBUG-75522
Change-Id: I61346edbd87389f66965a906ac337fc1f5300e5c
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
2019-05-08 12:34:19 +00:00
Alexandru Croitor
0efe6fc90f Don't link against dbus-1_nolink when dbus_linked feature is off
dbus1_linked is only evaluated to true when the dbus package is found.
If it was not found, then it makes no sense to link against the
_nolink target, because no package was found in the first place.

When the package is not found, QtDBus uses a minimal dbus header which
is included with QtDBus sources, so there is no need for the _nolink
target.

This amends cc141cc5c6 and fixes a build
failure on macOS.

Change-Id: I71dcbb7465ad13b0bf03579f51412c373125caba
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2019-05-08 12:32:53 +00:00
Tor Arne Vestbø
19d13f8b2d macOS: Deliver and handle screen change unconditionally
We can't rely on the previous screen and current screen to accurately
reflect whether or not the window has been moved from one screen to
another, or if the window just stayed on the same screen but the screen
was reconfigured by macOS. The reasons for this are many-fold, but
include factors such as Qt using the screen of the top level window
to resolve the screen of the child windows, and AppKit delivering
screen change events in an order that makes things harder to track.

The result is that we need to always send screen change events, for
all windows, including child windows, and we also need to restart the
display link by re-requesting an update request if needed, so that
child windows that are running animations will continue to animate
on the new screen.

Change-Id: I0b87849c41323e92c08f5115842be067fa8f8490
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
2019-05-08 12:24:19 +00:00
Tor Arne Vestbø
9054950b7c macOS: Always respond to cursorUpdate by applying custom cursor if set
Calling super will push the default arrow cursor, so we should only
do that if our own cursor has been unset.

Change-Id: I71d8934e7eab2b15e150730e2282e7063ada305a
Fixes: QTBUG-75552
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-05-08 12:23:47 +00:00
Vova Mshanetskiy
8ea3300a08 QAndroidInputContext: Fix getTextBefore/AfterCursor() in mid. of preedit
getTextBeforeCursor() and getTextAfterCursor() were not properly
handling the case when the cursor is in the middle of preedit string
(just as TODO comments inside these functions were saying). This was
causing problems with Gboard when the user focuses a text editor by
tapping in the middle of a word.

Fixes: QTBUG-58063
Change-Id: I4a580a74d79965816557bfb342337975348d1c45
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2019-05-08 14:52:31 +03:00
Vova Mshanetskiy
d0741f4267 QAndroidInputContext: Fix most "Input method out of sync" warnings
According to Android docs start == end in a call to setComposingRegion()
means finish composing. But this case was not being handled properly:
m_composingText was being assigned an empty string, but
m_composingTextStart was being assigned the value of start, which is
never -1.

There is one other possible cause of "Input method out of sync"
warnings, but it is tightly coupled with another bug, so it will be
fixed by a separate commit.

Change-Id: Ie475df84f330453ce4fc623e8b631b435d7d0042
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2019-05-13 14:52:47 +03:00
Frederik Gladhorn
73ca3dbf49 Windows Accessibility: window should be focusable
Fixes: QTBUG-75001
Change-Id: Iac67b9bba70317f8d28ac2d355d584417d1ffebf
Reviewed-by: André de la Rocha <andre.rocha@qt.io>
2019-05-21 09:26:10 +00:00
Massimiliano Gubinelli
a4bd4565cc Emit QMenu::aboutToShow() before platform specific code
Send the aboutToShow() signal to QMenu before synchronising the
widgets for the menu items. This fixes a bug where if new
QWidgetActions are added to the menu from a slot triggered by the menu's
aboutToShow() signal, then such new actions do not shows up correctly on
Mac. Other platforms are not affected by the change.

Fixes: QTBUG-75826
Change-Id: Ic245d3fbc7ddde6944cca6cdb8e8951380c846ec
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-05-16 12:33:45 +00:00
Laszlo Agocs
1f04b09446 eglfs/openwfd: do not purge QSurfaceFormat fields
Change-Id: I6c1d83624838362f6a3daa6c2b309fb518a25d4b
Fixes: QTBUG-75673
Reviewed-by: Janne Koskinen <janne.p.koskinen@qt.io>
Reviewed-by: Johan Helsing <johan.helsing@qt.io>
2019-05-08 15:51:19 +02:00
Frederik Gladhorn
516ab2a595 Windows Accessibility: Add UI Automation Window provider
This allows closing, minimizing and maximizing the window.

Fixes: QTBUG-74999
Change-Id: I8b3ad806a1767586c8cf7e5a1848fc0e525621cd
Reviewed-by: André de la Rocha <andre.rocha@qt.io>
2019-05-20 13:21:02 +00:00
Tor Arne Vestbø
5e743adc20 Don't try to retranslate strings for native color dialogs
If the native color dialog is in use we haven't created any of the
widgets and will crash when trying to update them.

Change-Id: I6c43cc47359110c3b9db7cacb62581446cc6f7a3
Fixes: QTBUG-75858
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2019-05-16 14:51:42 +02:00
Tor Arne Vestbø
387691498a macOS: Generate UTF-16 clipboard content without BOM
Qt on macOS has traditionally not included a BOM in the UTF-16 data,
but due to iOS requiring it it was changed in 4e196159. This had the
unfortunate side effect of breaking macOS applications that were not
prepared for the BOM, even if the public.utf16-plain-text UTI can have
an optional BOM, most notably Microsoft Excel. It also resulted in the
public.utf8-plain-text having a BOM, as that's automatically generated
by macOS based on the UTF-16 content we give it. Having a BOM in UTF-8
is technically fine, but not required, and recommended against.

The fact that iOS requires a BOM is a bit dubious, and most likely a
result of applications or system frameworks decoding the data using
NSUTF16StringEncoding, which assumes big-ending byte ordering if there
is no BOM, as opposed to public.utf16-plain-text which assumes native
byte ordering. Since we can't fix iOS our best bet is to include a BOM.

For macOS though, we revert back to the old behavior of not including
a BOM, since that seems to surprise macOS frameworks and applications
the least, even if having a BOM in public.utf16-plain-text should be
fully supported.

Longer term we should look at what kind of UTIs we generate. Most apps
on macOS do not generate public.utf16-plain-text, but instead generate
public.utf16-external-plain-text, which differs from the former in that
it assumes big-endian byte-ordering when there's no BOM. On iOS apps
seem to generate public.utf8-plain-text, and do not generate any UTF-16
UTIs. Moving Qt over to these UTIs would fix the problem as well, but
is a larger change that needs more research.

Change-Id: I4769c8b7d09daef7e3012e99cacc3237f7b0fc1a
Fixes: QTBUG-61562
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-05-20 13:31:34 +00:00
Friedemann Kleint
299675e665 tst_QMdiSubWindow::setSystemMenu(): Pass in High DPI/multi-screen setups
The window tends to grow to span screens in multi-screen setups; force it to
be on the primary screen by showing it maximized in that case.

Change-Id: I984ba7a4cd4abd1f862c59c8dca0e2275f44c724
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
2019-05-20 10:51:46 +02:00
Friedemann Kleint
18b336990f Brush up tst_QMdiSubWindow
- Use nullptr
- Use range-based for
- Use correct static invocation
- Set a title on shown windows to make it possible to identify
  slow tests
- Fix the class declarations, use override, member initializations
- Use Qt 5 connection syntax where possible
- Ensure top level widget list is empty after each test, delete left-over
  menu bars and disable menu animations

Change-Id: Ieeb943ea669cd139f1835088b816802e777a9676
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2019-05-20 10:51:46 +02:00
Morten Johan Sørvig
4c9758f1af QHighDpi: Simplify top-level window handling code
Introduce origin(QWindow *), which returns the point
around which coordinates should be scaled: the screen
origin for top-level windows, and (0, 0) for child windows.

The code paths for top-level and child windows can
then be combined.

Change-Id: I6b9cdbd9e7c2d9406e9137e325c4eb5c79e3ac9a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-05-14 19:31:16 +02:00
Andre de la Rocha
8be17f1fd5 Windows QPA: Fix QWheelEvent::buttons() after click on title bar
When the left or right mouse buttons are pressed over the window title
bar a WM_NCLBUTTONDOWN/WM_NCRBUTTONDOWN message is received. But when the
button is released, no corresponding UP message is received, but only
a WM_NCMOUSEMOVE or WM_MOUSEMOVE. This makes the internal mouse button
state stored in QGuiApplication get out of sync with the actual state,
resulting in an incorrect button state being used in QWheelEvent.
This patch detects the button release condition and generates the missing
release event.

Change-Id: I6dd9f8580bd6ba772522574f9a08298e49c43e61
Fixes: QTBUG-75678
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2019-05-18 03:15:06 +00:00
Oliver Wolff
a96a33d993 qtmain_winrt: Avoid nullptrs in str*cmp which cause crashes
When bringing an application back to foreground, args may contain NULL.
These nullptrs should not cause application crashes.

Fixes: QTBUG-75843
Change-Id: I642e3c359216e7706bcb13508399999a51a4fc2d
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2019-05-17 09:26:33 +00:00
Kai Koehne
b7aea2bcd3 Qt Widgets: Document CMake macros
Task-number: QTBUG-72159
Change-Id: Ib9fdf852583964cf07c4d26e0a6c74f0058e29f1
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2019-05-16 13:24:25 +00:00
Kai Koehne
57b4f6d56e Qt Core: Document CMake macros
Document public macros in Qt5CoreMacros.cmake. This will replace
the list in the current CMake Manual.

Task-number: QTBUG-72159
Change-Id: I377412fe0c1d0a9b232162bbab88ac830d2cac80
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
2019-05-16 13:24:08 +00:00
Friedemann Kleint
b88be04519 Make tst_qwidget_window pass on High-DPI screens (Windows)
Use a fuzz check (cf 6309062722) and a minimum
size similar to tst_qwidget to make the test pass on large monitors with or
without active scaling.

Change-Id: I5a9e28e38e1d007057894c349c94f0e6fe12009c
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2019-05-16 12:56:33 +00:00
Friedemann Kleint
e72e5aa83a Brush up tst_QWidget
- Use nullptr
- Fix C-style casts
- Fix redundant bool expressions
- Fix else after return
- Remove unnecessary casts to int from registered enums
- Fix most signedness-related warnings
- Use range-based for
- Use correct static invocation
- Set a title on shown windows to make it possible to identify
  slow tests
- Fix the class declarations, use override, member initializations
- Use Qt 5 connection syntax
- Remove unused variables
- Streamline code in some cases

Change-Id: I1350b382b0b7d0f3198039fdc78892cfa1dd498d
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2019-05-16 06:24:27 +00:00
Friedemann Kleint
909f793de1 Brush up tst_QWindow
- Use nullptr
- Fix C-style casts
- Remove unnecessary casts to int from registered enums
- Fix most signedness-related warnings
- Use range-based for
- Use correct static invocation
- Set a title on shown windows to make it possible to identify
  slow tests
- Fix the class declarations, use override, member initializations
- Streamline code in some cases

Change-Id: I4c9b99126cff02136def0e03accdf1129fe6d72b
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
2019-05-15 19:57:06 +00:00
Friedemann Kleint
ef3b585ddf Brush up tst_QApplication
- Use nullptr
- Fix C-style casts
- Use range-based for
- Use correct static invocation
- Set a title on shown windows to make it possible to identify
  slow tests
- Fix the class declarations, use override, member initializations
- Use Qt 5 connection syntax; use lambdas where applicable
  to remove helper slots
- Streamline code in some cases
- Replace helper function to convert touch points by the one in
  QWindowSystemInterfacePrivate
- Use a logging category for the debug outpt, silencing some output

Change-Id: Ia46c7ad7c08f3afc8e5869ea99b66e406de97781
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
2019-05-15 19:56:50 +00:00
Tobias Hunger
0c498ef4ff CMake: pro2cmake.py: Do not fail when run from .pro-file directory
Change-Id: I285b05986e3a58efc060ca0b5732f6e3f5121476
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-05-08 11:25:58 +00:00
Alexandru Croitor
9d96c8da78 Fix freetype target not being found when using vcpkg
vcpkg and upstream CMake find module define different target names for
the same package. To circumvent this, create our own Wrap find module,
and link against it. Inside the find module, try both target names.

Change-Id: Iba488bce0fb410ddb83f6414244f86ad367de72b
Reviewed-by: Liang Qi <liang.qi@qt.io>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2019-05-08 10:54:15 +00:00