Commit Graph

40022 Commits

Author SHA1 Message Date
Liang Qi
41f77a6179 Merge "Merge remote-tracking branch 'origin/5.12' into 5.13" 2019-08-12 19:40:48 +02:00
Joerg Bornemann
7f4f346e51 Fix escaping of < and > in QMake's XML generator
Having those characters in QMAKE_EXTRA_COMPILERS broke the generated
VS project file. They must be replaced by XML entities.

Fixes: QTBUG-1935
Change-Id: Iff1edbeabec4cedef777071682412970b7769f19
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-08-12 14:46:20 +02:00
Liang Qi
44c393f9b6 Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	config.tests/arch/write_info.pri
		Repair architecture config test for the WASM_OBJECT_FILES=1 build mode
	configure.pri
	tests/auto/gui/text/qtextdocument/tst_qtextdocument.cpp

Done-With: Jörg Bornemann <joerg.bornemann@qt.io>
Change-Id: I9e12088356eb5bc65b53211cd7a8e330cccd1bb4
2019-08-12 13:23:11 +02:00
Antti Kokko
bd2b4c3569 Add changes file for Qt 5.13.1
Change-Id: I763722f0cdfb0569c8f97063784c1a6407d22109
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
2019-08-12 11:22:36 +02:00
Morten Johan Sørvig
811465032b macOS: Don’t show hidden windows while z-ordering
Calling [NSWindow orderBack] will make the window visible
again, and will e.g. bring back closed menus on application
modality changes.

Fixes: QTBUG-77281
Change-Id: I2f89b852ea9f8ab34c709cec96d93fe305984fb9
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
(cherry picked from commit 3729695cc9)
2019-08-12 09:22:08 +00:00
Joerg Bornemann
e66f247ccf Doc: Extend QMake's documentation of RC_FILE and RES_FILE
RC_FILE is not an internal variable that "rarely needs to be
modified". Mention that it's about Windows resources and link to the
corresponding section.

RES_FILE: Add link to RC_FILE and the more general section. Also
rephrase "compiled Windows resource file" to "Windows resource
compiler's output file" which is more precise.

Fixes: QTBUG-8709
Change-Id: I19c61e6a9505d45fc13fefbcd0ba9441191aa42e
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Reviewed-by: Kavindra Palaraja <kpalaraja@luxoft.com>
2019-08-12 08:04:39 +02:00
Samuel Gaist
08f0db4a72 doc: Fix QImage Format_RGBX64 documentation
The current explanation refers to itself rather than Format_RGBA64.
This patch fixes that.

Change-Id: Idc4c44ca71813ea2bdddba0c936f772cb7091ca8
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Reviewed-by: Sze Howe Koh <szehowe.koh@gmail.com>
2019-08-11 22:31:14 +02:00
Morten Johan Sørvig
fcc5323a08 Make test less dependent on moving the cursor
The sendMouseMove() function calls QTest::mouseMove(),
which again calls QCursor::setPos() to move the cursor.
It then creates and sends a MouseMove event, using
the constructor which picks up the global position
by calling QCursor::pos().

On macOS 10.14, QCursor::setPos() may silently fail
if the user does not grant the application permission
to move the cursor (via a dialog). As result of this
the mouse move event gets an incorrect global position.

Provide the global position directly when creating
the event to make sure it gets the correct value.

Task-number: QTBUG-75786
Change-Id: I3e8df450fea802783a3d1dbe471753f502b42de3
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2019-08-11 12:01:54 +02:00
Morten Johan Sørvig
9bcbba36c7 QWizard: Account for missing background image on macOS 10.14+
We were loading “Background.png” from the KeyboardSetupAssistant
app bundle. As of macOS 10.14 that image is no longer
there.

Adjust auto tests and document the behavior.

Change-Id: Icb4dd73b3fa88927e87bb86db2bc9f7b4a8094f7
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-08-11 10:01:46 +00:00
Morten Johan Sørvig
3729695cc9 macOS: Don’t show hidden windows while z-ordering
Calling [NSWindow orderBack] will make the window visible
again, and will e.g. bring back closed menus on application
modality changes.

Fixes: QTBUG-77281
Change-Id: I2f89b852ea9f8ab34c709cec96d93fe305984fb9
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-08-11 10:01:36 +00:00
Morten Johan Sørvig
5d7f113320 Add nullptr guard to QHighDScaling::scaleAndOrigin(QPlatformScreen *)
Commit b6ded193 added an unconditional dereference
of the platformScreen pointer, for calls where nativePostion
is non-nullptr.

Change-Id: I4a6fbbd0337f91d4fcb76c17b4dc60e1b9ad10ed
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-08-11 12:01:26 +02:00
Thiago Macieira
ffc2d57223 QList: fix some integer cast warnings from 64- to 32-bit
Not tested because we're not promising to fix them all. Just those two
that were reported.

Fixes: QTBUG-77391
Change-Id: Iec9c051acd73484c8d94fffd15b91f5e6348635d
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2019-08-10 17:10:47 -07:00
Thiago Macieira
a08ac1986d Fix integer overflow in QCryptographicHash's SHA-3 support
Because 256 MB * 8 = 2 Gbit, but length*8 is a signed integer overflow,
hence UB.

Can't really autotest this. Not all systems where we're going to test
can allocate 256 MB of RAM.

[ChangeLog][QtCore][QCryptographicHash] Fixed a bug that caused the
SHA-3 and Keccak algorithms to crash if passed 256 MB of data or more.

Fixes: QTBUG-77362
Change-Id: Iec9c051acd73484c8d94fffd15b91f4b1450f5d7
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2019-08-10 17:09:18 -07:00
Simon Hausmann
aca43d29f8 Fix sign change warning
The conversion from int to uint is deliberate here, so let's cast and
avoid a warning for users compiling with warnings enabled.

Change-Id: I7136d6161ace735be49f8d987338f6d401a5c78a
Fixes: QTBUG-77245
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2019-08-09 09:32:59 +02:00
Yuhang Zhao
d502b19b28 Fix std detection for win32-clang-msvc
clang-cl will never support C++ standards newer than
C++14 without these flags.
I didn't add them to msvc-based-version.conf because
on Windows, only clang-cl use the same flags with MSVC,
both ICC and MinGW have their own flags. So they are
clang-cl specific flags.

Change-Id: Ia44a5ea4237c77ea5e897fffded32cbc008a4729
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2019-08-09 15:16:18 +08:00
Thiago Macieira
48b3ec6e8e QBitArray: change modulo 8 with bitwise-AND 7
They're the same only for unsigned values. Modulo of negative numbers
since C++11 has an expected behavior and generates more code:

%rax = %rax & 7:
        andl    $7, %eax

%rax = %rax % 8 with GCC:
        cqto
        shrq    $61, %rdx
        addq    %rdx, %rax
        andl    $7, %eax
        subq    %rdx, %rax
[read as ((%rax + (%rax < 0 ? 7 : 0)) & 7) - (%rax < 0 ? 7 : 0))]

With Clang:
        movq    %rax, %rcx
        sarq    $63, %rcx
        shrq    $61, %rcx
        addq    %rax, %rcx
        andq    $-8, %rcx
        subq    %rcx, %rax

Change-Id: Ife213d861bb14c1787e1fffd15b83b004be7eba0
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2019-08-08 20:29:32 -07:00
Thiago Macieira
6ce9404a6e QBitArray: fix fromBits() and actually test it
When I initially added it, it was ony for QCborValue, but I never added
the tests. Turns out there were two bugs:

[ChangeLog][QtCore][QBitArray] Fixed two bugs that caused QBitArrays
created using fromBits() not to compare equal to the equivalent
QBitArray created using other methods if the size was zero or not a
multiple of 4. If the size modulus 8 was 5, 6, or 7, the data was
actually incorrect.

Fixes: QTBUG-77285
Change-Id: Ife213d861bb14c1787e1fffd15b70573d162042c
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2019-08-08 20:27:04 -07:00
Joerg Bornemann
39e937a538 Fix host architecture detection for canadian cross builds
If the host architecture is different from -platform (canadian cross
build with -external-hostbindir) then we cannot use QMAKE_HOST.os to
deduce the executable extension for that platform, because this value
comes from the qmake binary that was pointed to by
-external-hostbindir.

Move the target name deduction mechanism to the actual configure test
.pro files to make sure the right scopes are available, and write the
deduced target name to a text file. That text file is read by
qtConfTest_architecture to get the right binary to analyze.

Fixes: QTBUG-77286
Change-Id: I68b844dd51dbfda6432a4b0dca6331899c82255f
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-08-08 14:26:11 +02:00
Heikki Halmet
c76b86aec6 BLACKLIST contains_QPointF for msvc-2019
Task-number: QTBUG-77312
Change-Id: I5197d160d9b3c70b538c2e5a43c31120e1bed5f0
Reviewed-by: Tony Sarajärvi <tony.sarajarvi@qt.io>
2019-08-08 15:20:23 +03:00
Timur Pocheptsov
aef0fba3c5 QCocoaMenuLoader: get rid of lastAppSpecificItem
Look it up when needed instead. Also, simplify our
ownership logic - do not retain/autorelease that
is already owned by a menu (via its itemArray).

Fixes: QTBUG-76523
Change-Id: I60a2ed0d192396baf99eec7b37fa5cc10e5db626
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-08-08 13:15:36 +02:00
Lars Knoll
afb326f071 Refactor lockedAlphaMapForGlyph
Simply return a Glyph pointer and not a QImage to avoid allocating and
deleting lots of d pointers for QImage when drawing text. Saves one
new/delete pair per glyph drawn and speeds up text drawing by 10% for
relatively large glyphs (probably more for smaller ones).

The qtext::paintLayoutToPixmap() benchmark shows a 16% improvement
in performance with this change.

Renamed the method to glyphData().

Change-Id: I7a353de521e4f4321c770fb1ac6043d33f6f332c
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-08-08 11:18:02 +02:00
Tor Arne Vestbø
6ac610c79b Allow specifying explicit SDK version on Apple platforms
This enables building against the latest SDK, while still opting out
of features that this SDK normally enables, by lowering the SDK version
set in the BUILD_VERSION/VERSION_MIN_MACOSX load command.

Change-Id: Id5f13524740bfbf5eda10a5d0c2e3fda04bf3f52
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2019-08-08 10:27:28 +02:00
Ville Voutilainen
ca20b44959 A GCC 4.8 build fix
Change-Id: Ic128486711118e1124739e8dca30547ab8ba9816
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2019-08-08 10:53:53 +03:00
Jason Haslam
4d9375020c macOS: Fix tab button rendering issue
This fixes rendering artifacts for the specific case of the first
unselected vertical (west) tab button in a tab bar. The popup button
gets drawn at the beginning of the tab bar instead of translated to the
actual location of the tab.

Fixes: QTBUG-76385
Change-Id: I17112c56eabacf34e470314d4cc6b263ba632ec1
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2019-08-08 01:38:10 -06:00
Eskil Abrahamsen Blomfeldt
a3dec41cf1 Add attribution for AGLFN
We were missing attribution for the AGLFN tables.

Task-number: QTBUG-70968
Change-Id: Ib84cbd25c9f7c49611761c9eba16624de5b77dd2
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2019-08-08 07:07:37 +02:00
Eskil Abrahamsen Blomfeldt
79e0effead Fix crash in QTextDocument::clearUndoRedoStacks()
When calling QTextDocument::clearUndoRedoStacks() with UndoStack,
there were two bugs: The first was that we were retrieving
the item at "undoState" and deleting this. This is actually the
upper limit of the for loop. If the stack does not contain any
redos, then it would be == undoStack.size() and we would assert.

If there were redos, then we would delete the item at undoState
multiple times (actually undoState times).

In addition, when the loop exited, we first removed the dangling
pointers using remove() and then there was a weird resize() to
the new size minus the old undoState.

This would either assert because we tried to resize to a negative
number, or it would arbitrarily remove items from the stack.

[ChangeLog][QtGui][Text] Fixed a crash bug in
QTextDocument::clearUndoRedoStacks(QTextDocument::UndoStack).

Task-number: QTBUG-69546
Change-Id: I8a93e828ec27970763a2756071fa0b01678d2dcd
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
2019-08-08 07:07:20 +02:00
Eskil Abrahamsen Blomfeldt
1880fba971 Android: Fix QMenu on 64 bit
The platform menu tags in Qt are actually the pointers, so they are
64-bit values when the build is 64 bit. Since menu IDs in Android
are 32-bit ints, we cannot cast back and forth like we do. To fix
this, we add a separate hash of menu IDs to allow mapping between
Java and C++. For easier book-keeping, we add the hashes to the
menu bar and menu classes, so that we can easily recycle old menu
IDs when they are no longer in use.

Note that overriding the tag on the menus by calling setTag() will
not work, since Qt Widgets will later override it again by setting
it back to the menu's pointer.

[ChangeLog][Android] Fixed an issue where menus would not work on
64 bit builds.

Task-number: QTBUG-76036
Change-Id: Icaa1d235d4166331669139251656ea0159e85195
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
2019-08-08 07:06:05 +02:00
Qt Forward Merge Bot
7b5138da16 Merge "Merge remote-tracking branch 'origin/5.12' into 5.13" 2019-08-08 01:00:21 +02:00
Qt Forward Merge Bot
2b38408cbc Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I4c0fd501db974fb8339944b8df845336776d80a9
2019-08-08 01:00:08 +02:00
Timur Pocheptsov
36cc171b93 tst_http2::connectToHost - fix flakiness
some assumptions were incorrect: our test server immediately sends
its SETTINGS frame, as a result we have to reply with client preface +
SETTINGS(ACK). So QVERIFY(!prefaceOK) was wrong from the beginning and
was only passing by pure luck.

Change-Id: Ie43f0d4ac41deb0e5339badaae6149a9b2f9d9b3
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
2019-08-07 18:57:31 +02:00
Laszlo Agocs
53a6f7b783 eglfs: Fix raster windows
Also sanitize the initial WebAssembly hack. Both eglfs and wasm lack the concept
of true raster windows. A QWindow with RasterSurface is rendered with OpenGL
no matter what. The two platforms took two different approaches to work around
the rest of the machinery:

- wasm disabled the QOpenGLContext warning for non-OpenGL QWindows,

- eglfs forced the QWindow surfaceType to OpenGLSurface whenever it was
  originally set to RasterSurface.

Now, the latter breaks since c4e9eabc30, leaving
all raster window applications failing on eglfs, because flush in the backingstore
is now checking the surface type and disallows OpenGLSurface windows. (just like
how QOpenGLContext disallows RasterSurface windows)

To solve all this correctly, introduce a new platform capability,
OpenGLOnRasterSurface, and remove the special handling in the platform plugins.

Change-Id: I7785dfb1c955577bbdccdc14ebaaac5babdec57c
Fixes: QTBUG-77100
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-08-07 11:46:19 +00:00
Tor Arne Vestbø
fccb519809 Don't rely on QWidget::internalWinId in QWidgetBackingStore
QWidget does not handle QWindow and QPlatformWindow being destroyed
behind its back, and the QWidget state for internalWinId and the
Qt::WA_WState_Created attribute can easily get out of sync with
reality.

To avoid QWidgetBackingStore mistakenly thinking that a widget does
not have a platform window it can operate on we use the QWindow and
QPlatformWindow handles directly, instead of relying on the winId.

This is a stop gap until we can teach QWidget to deal with dynamic
changes to its underlying window handles.

Change-Id: Ib09bea2ad62c42e9667a20ca6b5faf0f957288da
Fixes: QTBUG-74559
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2019-08-07 13:45:34 +02:00
Andreas Hartmetz
0ea7360eaa Fix two examples in QUrl::toLocalFile() documentation
Change-Id: Ib17844e1dd696a41815bdf58924ff40d684884a8
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
2019-08-07 12:56:58 +02:00
Marc Mutz
787e498487 QMutexPool: fix memory order of atomic operations
The array of QAtomicPointer<QMutex> can be initialized using relaxed
stores of nullptr, since nullptr is the whole data. But once we store
an actual QMutex pointer in the array, we need to publish the indirect
data thus created. We did this, with testAndSetRelease(); what was
missing was a corresponding acquire fence on load, without which there
is no happens-before relationship between the writes performed by the
QMutex ctor and the reads performed by a subsequent mutex.lock(), say,
on the same data.

Fix by adding acquire fences to all loads. That includes the dtor,
since mutexes may have been created in different threads, and never
been imported into this_thread before the dtor is running.

As a drive-by, return a new'ed QMutex that was successfully installed
directly to the caller, without again going through a load-acquire.

Fixes: QTBUG-59164
Change-Id: Ia25d205b1127c8c4de0979cef997d1a88123c5c3
Reviewed-by: David Faure <david.faure@kdab.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit 65b8f59e04)
(cherry picked from commit da38f0d691d9d7eacfac5fbcbd47b887bd59bd39)
2019-08-05 19:30:37 +00:00
Thiago Macieira
64d9492076 Fix race condition on qt_create_tls() on Windows
If this function is called by multiple threads, more than one could
reach the mutex locking and call TlsAlloc(), but only the last one would
save the data. The others would be leaked and, worse, be used by those
other threads.

[ChangeLog][QtCore][QObject] Fixed a resource leak caused by a race
condition if multiple QObjects were created at the same time, for the
first time in an application, from multiple threads (implies threads not
started with QThread).

Fixes: QTBUG-77238
Change-Id: Ife213d861bb14c1787e1fffd15b63a5818bcc807
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2019-08-05 10:14:47 -07:00
Ville Voutilainen
4f116f00fc Fix GCC 4.8 build
Change-Id: I4994146b359e8e37f6c0fa1b27f03fb9e800fdd5
Fixes: QTBUG-77218
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2019-08-05 15:50:42 +03:00
Liang Qi
f3c816befe Merge "Merge remote-tracking branch 'origin/5.12' into 5.13" 2019-08-05 10:03:24 +02:00
Liang Qi
f3b28e8021 Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	qmake/generators/unix/unixmake2.cpp
	src/plugins/platforms/cocoa/qcocoawindow.mm

Change-Id: Iba7aa7324f35543e0297a3680956420058cd3630
2019-08-05 09:28:48 +02:00
Joerg Bornemann
8c0787cfa1 Fix dependency_libs entry of .la files
Libtool cannot cope with absolute paths in the dependency_libs entry.
We split absolute paths into -L and -l here.

Change-Id: I30bf11e490d1993d2a4d88c114e07bbae12def6d
Fixes: QTBUG-76625
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-08-03 21:47:55 +02:00
Tor Arne Vestbø
455963ce49 macOS: Don't require setting all three color buffer sizes in QSurfaceFormat
Change-Id: Iaa6eb4d64f549a31aa5c53145e8b37facec4ea78
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-08-02 18:59:24 +02:00
Pavel Artsishevsky
a22bb694ce Fix QPainter's ColorDodge and ColorBurn composition modes
Added checking corner cases (more specific formulas) in
color_dodge_op()/color_dodge_op_rgb64() and color_burn_op()/color_burn_op_rgb64()
to produce correct results for any input.

Task-number: QTBUG-77231
Change-Id: I274f80b356bd4236a9176a84a95604c2eb01787a
Reviewed-by: Konstantin Tokarev <annulen@yandex.ru>
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
2019-08-02 12:46:53 +03:00
Timur Pocheptsov
ec62033bc2 tst_http2::connectToHost - add a fix for SecureTransport backend
One of the tests above was unsetting a variable that enforces
the use of a temporary keychain. We have to set it back, otherwise
the test is failing. What surprises me though - why I had this
problem only locally and not on CI? Apparently, SecureTransport
is not covered by our configurations ...

Change-Id: I0ff1e3e304632869391ed61213c245b949d8c778
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
2019-08-01 17:37:53 +02:00
Tor Arne Vestbø
662798d785 macOS: Add system detection and version defines for macOS Catalina (10.15)
Change-Id: I127efe752ebb70825f1b31f0d64c4293d1c71820
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
2019-08-01 15:25:01 +02:00
Tor Arne Vestbø
360000342a macOS: Improve screen positioning during window creation
Allow AppKit to resolve screen for NSWindow lazily in the case where the
position is outside any known screen. And explicitly set the style mask
if detecting the corner case of positioning a window in the unavailable
space on a rotated screen.

In testing the effect of creating the window with a borderless style mask
and then updating the mask did not seem to have any visual consequences,
but we try to limit this mode just in case by only enabling it in the
corner cases we detect.

Change-Id: I4b7fcc6755a1ad5ff2683bec79d80a78226edae0
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2019-08-01 15:24:55 +02:00
Tor Arne Vestbø
89e97e9937 Pass qmake arguments when creating Xcode project from Makefile
Change-Id: I0020273b200465f44a135848b4fd505793e85c30
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-08-01 15:24:25 +02:00
Tor Arne Vestbø
a34b0855f1 macOS: Don't assume NSWindows will be created on the screen we request
The user may have assigned the application to start up on a specific
display, in which case the window's screen is nil after creation, and
the resulting screen will be delivered as a normal screen change once
the window is ordered on screen.

Fixes: QTBUG-77154
Change-Id: Idade6d833e31654db239243f2430166b5d86eca2
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
2019-08-01 15:23:56 +02:00
Timur Pocheptsov
bd8ef7fe24 Blacklist tst_http2::connectToHost
Test if flakey.

Change-Id: I1f956f47ab4cf0602f3631e4f7908df35f5ce83f
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-08-01 13:18:02 +00:00
Marc Mutz
9ad8debe38 qlalr: fix compilation with C++20
std::not1 is deprecated in C++17, removed in C++20.

Use its replacement, std::not_fn.

Change-Id: I37d4929c81c2a5befeb44f954ae77b23960d2ff0
Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
2019-08-01 11:20:27 +00:00
Friedemann Kleint
174061f9f3 QHighDPI: Fix broken scaling of QPoint(F)
For some reason, the overload resolution of the
High DPI scale() functions introduced by
b6ded193ee chose the
wrong overloads for QPointF and/or QPoint; it fell
back to the generic template intended for qreal,
QSize, etc, ignoring the origin. Remove the
template and spell out all overloads.

Fixes: QTBUG-77255
Change-Id: I5661f16f7326f65156f646f430f5a0c71d5302d2
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-08-01 13:20:23 +02:00
Volker Hilsheimer
3d7bd7ad19 Fix hit testing in non-client area of fixed-size windows, don't show resize cursors
The m_windowState member is never updated regarding active state;
isActive is instead reimplemented to query the window manager, so use
that.

To extend the area where the user can move the window over the entire
titlebar of fixed-height windows, just test whether the mouse position
is within the titlebar.

Change-Id: I6b87aacd0bdab511cfd4959df1114af5c6013852
Fixes: QTBUG-77220
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2019-07-31 20:13:49 +02:00