Commit Graph

33096 Commits

Author SHA1 Message Date
Oswald Buddenhagen
0f1b8fd2dc work around flex bug
flex emits code using isatty(), but fails to include the required
unistd.h. we can work around it by including the header ourselves.

Task-number: QTBUG-64771
Change-Id: I05313eeb79f7a0e25365dee5f05a0142f87209ae
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2017-11-30 20:24:39 +00:00
Filipe Azevedo
d80fde62ed Fix broken QNAM::networkAccessible()
When switching on/off multiple time the wifi (mainly, but not only) on
ios/macos the QNAM may wrongly stay on a NotAccessible state while the
configuration is Active.
This change make sure the QNAM::networkAccessible() is correctly
reporting the accessibility.

Task-number: QTBUG-49751
Task-number: QTBUG-58275
Task-number: QTBUG-60366
Change-Id: I238ab32030fbaa8072cce341db8da6bcfc346035
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2017-11-30 16:03:48 +00:00
Tor Arne Vestbø
1a55c92933 iOS: Compute screen available geometry based on safe area insets
In addition to the (deprecated) applicationFrame property, we
base the available geometry on the root view's safe area, which
also takes into account system-reserved areas on iPhone X, and
the screen's bezel in the case of tvOS.

Change-Id: I252d960a0e486dd0c7e30843f88c0bf5684feb24
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2017-11-30 15:59:20 +00:00
Eskil Abrahamsen Blomfeldt
109290753b Android: Fix note for host architecture mismatch
The qtConfAddNotice was a typo, so this note was missing from
config.log and the build would fail with no explanation.

Change-Id: Iae22f92c1ba6bdf96d41a7cc608b9aedd6863b1f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2017-11-30 14:39:03 +00:00
Friedemann Kleint
dae308d892 qprintengine_win.cpp: Fix -Wclazy-range-loop
qprintengine_win.cpp:1502: warning: Missing reference in range-for with non trivial type (QPrint::InputSlot) [-Wclazy-range-loop]

Change-Id: If6e55c1748e05e32aaa32a16063ba491fe242952
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2017-11-30 15:22:51 +00:00
Timo Aarnipuro
dc4b4e9949 Build integrityhid support only if it is available
Change-Id: I6e0aa2f74516d4c0a1905b188f195834d395584b
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2017-11-30 12:45:00 +00:00
Friedemann Kleint
58b70c2f1a tst_QFileSystemModel: Stabilize readOnly(), sortPersistentIndex()
The tests start to show flakyness on Linux in 5.10 (rowCount() check
failing). This seems to point to a race condition between the files
showing up and the file system watchers of QFileSystemModel starting.

To fix this, close the file and wait until it shows up in the directory
before pointing the QFileSystemModel to it. The tests then no longer
rely on the file system watchers.

Change-Id: I39cffb4cacf6843e8e4180efb405345307c78dd8
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
2017-11-30 10:16:48 +00:00
Oliver Wolff
6508fdca1d ANGLE: D3D11: Fix shared handle support detection for WARP when MinGW is used
The MinGW version we support supports IsWindows8OrGreater so that we can
check the windows version properly. As the OpenGL detection falls back
to WARP in case of RDP it was possible, that shared handles were wrongly
stated as supported, which caused crashes in users' code.

Task-number: QTBUG-64657
Change-Id: Iaca2bd169f2764cf6ec68a1d36112a735246b29a
Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2017-11-30 05:23:36 +00:00
Błażej Szczygieł
da50a0b38c xcb: Set executed drop action when drop is outside the application
Task-number: QTBUG-62815
Change-Id: I13ee1a3a7e9515d827d29ada38bc0d396f4800d7
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
2017-11-29 23:05:06 +00:00
Tor Arne Vestbø
85eef0e5e0 iOS: Improve logging during application startup
Change-Id: I15c1980d7c532c94b34e612bb781c8ed5bf096a0
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2017-11-29 23:04:22 +00:00
Alexander Shevchenko
813fa3f50f unify windows mkspecs: update description
Common changes to mingw-w64, ICC on Windows and MSVC toolchains:
- update toolchains description similar to 'gcc-base.conf'.

Change-Id: Ie456c6cec86c0d1c0107ca84a0fa7855666df91e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2017-11-29 23:03:56 +00:00
Robert Szefner
e195620d71 QPSQL: Remove semicolon after Q_DECLARE_SQLDRIVER_PRIVATE
The semicolon is unnecessary and QtCreator warns of it.

Change-Id: I20f803d1ea0136080ff4dc4f7d9863fd8028992e
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2017-11-29 14:13:07 +00:00
James McDonnell
49597a7b58 Correct the vertex used to calculate v1/v2Frac
The NoClip version of the drawTriangle code had the vertices swapped.

Task-number: QTBUG-50845
Change-Id: I731dafee6cc140ea017b3b7d1051a27ad3081aa7
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2017-11-29 14:04:29 +00:00
Friedemann Kleint
bc9941db42 tst_QNetworkReply: Blacklist putToFtpWithInvalidCredentials for Windows
Task-number: QTBUG-62860
Change-Id: Ibf4d7de9eedc2236375ad10ca4bea08055c7ae00
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2017-11-29 13:55:35 +00:00
Marc Mutz
8f3ad56191 [doc] Document QString{,Ref}::split() behavior with empty 'sep'
We actually test for this already in tst_QString::split().

Change-Id: I35fe8f90900ea9c8e6251facdb3326b9226348d0
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2017-11-29 13:52:50 +00:00
Tor Arne Vestbø
038e473cfa iOS: Don't treat AppleTV as an iDevice when resolving physical DPI
Change-Id: I07ac92a7b2d8c65b7d70a4f2ed5f96f8f4d99ef0
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2017-11-29 12:18:40 +00:00
Tor Arne Vestbø
81908abd5e iOS: Update screen metrics (physical DPI) for the latest set of devices
We were missing some recent iPads, and the iPhone 8 Plus and X.

Change-Id: Ib65644a277a1cbd75ccb360b79b9ac8af935c741
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2017-11-29 12:18:28 +00:00
Thorbjørn Lund Martsum
fb880bbdff QMenu: Corner case size fix (high DPI + multi screen)
We always need to set the QMenu screen explicit also when
it is about to be shown on the primary screen.
The reason is QWidget::metric (called from style/sizeHint)
may use qApp->devicePixelRatioF() when it does not
know about the topLevelWindow. That may not be the same
value as DPR on primary screen. It can be argued that
it likely is a bug in QWidget::metric, but fixing that
looks to be a somewhat dangerous behavior change.

Task-number: QTBUG-59794
Change-Id: I6ed0e808aa31bee5b77c0e19ce61a77548fdbb38
Reviewed-by: Morten Kristensen <msk@nullpointer.dk>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
2017-11-29 07:31:45 +00:00
Robert Szefner
203fb83803 QSqlQuery: Remove temporary variable in navigation functions
Change-Id: I33836a75e1d2e5663f81a33a195d0cb21760e1f8
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2017-11-29 06:54:15 +00:00
Joni Poikelin
3acf5d61a1 Fix DB2 plugin building on Linux 64bit
Task-number: QTBUG-59358
Change-Id: I2e7d52b31f354868c8c4435d8cabe3525d22ede2
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2017-11-29 06:40:37 +00:00
Joni Poikelin
b764c4d0aa Fix unix QPrintDialog initially selected printer
Unix QPrintDialog always set default printer as selected printer even
though something was explicitly requested.

[ChangeLog][QtPrintSupport][QPrintDialog] Properly pre-select explicitly
requested printer on Unix.

Task-number: QTBUG-63933
Change-Id: I6289f759d480b4891f4ddd7ff5aad3ae9ab4bc75
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2017-11-29 06:40:35 +00:00
Gabriel de Dietrich
60dfd59a60 gui/configure.json: Make -{system,qt}-xcb force enabling xcb
... just like -xcb does implicitly. Otherwise, failure to detect
system-xcb would silently fall back to -no-xcb despite obviously
contradicting the user's request (-qt-xcb always worked anyway,
as there is no test that can fail).

Change-Id: I6f3145fac0881e7847c4a70547fce206e797a9bb
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2017-11-28 23:32:43 +00:00
J-P Nurmi
41667f7f14 Android: fix scrolling using a touch keyboard on Blackberry
This is a follow-up commit to 97eec16e.

Blackberry tries sending touchpad events first, and if not consumed,
it sends synthetic mouse wheel events as a fallback. This makes touch
keyboard scrolling work in native Android ListViews and other views
that do not handle SOURCE_TOUCHPAD motion events. Qt apps, however,
blindly accepted all generic motion events, so synthesized mouse wheel
events were never sent. => Make QtSurface & QtNative accept only those
motions events that are actually handled.

Task-number: QTBUG-51165
Change-Id: Iefbbf1e3e1cc3da86afc4c87c19671cc6c5fa145
Reviewed-by: Kai Uwe Broulik <kde@privat.broulik.de>
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
2017-11-28 22:21:42 +00:00
Marc Mutz
67391f0a57 Fix aliasing problem in QVector::removeAll()
Since removeAll() takes its argument by cref, if passing a reference
to an element of the container to removeAll(), the element may be
deleted (overwritten) by anyother value, leading to UB.

Add a test that actually happens to fail for me without the patch,
even though that might not be guaranteed (we may invoke UB).

Change-Id: If8c795113aeb515f4a9bdf1e072395b932295667
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2017-11-28 21:58:50 +00:00
Tor Arne Vestbø
a0871ad225 iOS: Deliver all QWindowSystemInterface events synchronously
On iOS we want all delivery of events from the system to be handled
synchronously, as that's what the system expects.

We don't need to add a delivery template argument to each function
in QWindowSystemInterface that we want to delivery synchronously;
that's only needed for functions that a platform normally sends
asynch, but in some cases want to delivery synchronously.

For always delivering events synchronously we just need to change
the default delivery method.

The only events affected by this are the screen changes, and
window state change, which were not synchronous before, but
should be. All other events were already synchronous, though
either explicit delivery, of a flush.

Change-Id: Ib20ca342d1c076be0fbcf018c83735a416769cfe
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2017-11-28 21:25:23 +00:00
Thiago Macieira
5f66f87181 Stop depending on test.macieira.org
We have had test.qt-project.org for close to 3 years now.

Change-Id: I71488efd29b645f7b228fffd14fadf4627288243
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
2017-11-27 21:48:20 +00:00
Thiago Macieira
6a9d076e87 QUdpSocket: Work around WSARecvMsg quirk relating to no control block
WSARecvMsg does not return the sender in WSAMSG::name if WSAMSG::Control
isn't set. This makes no sense, so I'm assuming it's an API quirk we
need to work around.

[ChangeLog][QtNetwork][QUdpSocket] Fixed a regression from Qt 5.9.3
caused by an apparent Win32 API quirk we triggered when using
readDatagram(), resulting in an invalid QHostAddress sender address.
receiveDatagram() was not affected.

Task-number: QTBUG-64718
Change-Id: I71488efd29b645f7b228fffd14f9d84cc205c4b3
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2017-11-25 20:50:55 +00:00
Tor Arne Vestbø
fa2a653b3b Initialize QLoggingRegistry rules on first use
Allows categorized logging before QCoreApplication has been created,
which otherwise would silently fail to output anything because the
category would never be enabled, despite QT_LOGGING_RULES being set.

Change-Id: I1861e5366ea980dff2ffa753b137276c77278eee
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
2017-11-25 10:01:35 +00:00
Thiago Macieira
ea18eec931 Merge "Merge remote-tracking branch 'origin/5.9.3' into 5.9" into refs/staging/5.9 2017-11-25 08:52:40 +00:00
Giuseppe D'Angelo
3587a25238 QFlags: support enum classes in setFlag()
Unary ~ is not defined for enum classes, so we need a cast.

Change-Id: I79d495ebcc24ab960da8dae3be08eb307a9de448
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2017-11-24 18:23:34 +00:00
Timur Pocheptsov
655cbb00a0 Handle HostNotFoundError correctly for HTTP/2
When processing host lookup error if-statement only checks the connection
type SPDY, which is not right - it could also be HTTP/2. As a bonus:
QT_NO_SSL conditional inclusion is not needed - HTTP2 can be 'clear text'
and SPDY enumerator is defined even in no-tls build (and is just a
noop here). Also, improve our somewhat cryptic message in 'Should not happen'
else branch - 'cannot dequeu' says nothing about HostNotFoundError.

Task-number: QTBUG-64721
Change-Id: Ib0346b8717c2dbddaffab690298f3cae01e338ea
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2017-11-24 18:09:47 +00:00
Mårten Nordheim
5a235da270 tst_QTcpSocket: fix disconnectWhileLookingUp
... and unblacklist it on Windows.

From what I can tell there is no particular reason why this test fails
other than that it is a little too slow sometimes (these things happen).

So, to fix the test I bumped the timeout, but to avoid the test running
for longer on every test-run it now also ends when the socket enters
the "Unconnected" state.

Previously it failed 171/500 times, and after this patch it failed
0/1000 times.

Change-Id: I4266bff6b91aaaf502ee66265d01c3a177706402
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io>
2017-11-24 04:54:58 +00:00
Liang Qi
19378fa008 Merge remote-tracking branch 'origin/5.9.3' into 5.9
Change-Id: I9add7e07ff1b6a1cf52f59dbb8319f30e114e5fc
2017-11-23 09:47:49 +01:00
Tor Arne Vestbø
eade2255ea Windows: Resolve QStandardPaths config location without qApp instance
Calling QCoreApplication::applicationDirPath() requires an app instance,
but on Windows the implementation just relies on qAppFileName(), which
does not require any instance. As resolving the standard paths could
be needed before QCoreApplication instantiation, e.g. for categorized
logging, we use qAppFileName() directly.

Change-Id: Id882cebd528bcb8e945e73a83f1dc3d599b74d1d
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
2017-11-22 21:27:45 +00:00
Tor Arne Vestbø
fb2e795c6e iOS: Take UIWindow bounds into account when making window fullscreen
When an app is in split-view mode, the app can't use the full bounds of
the screen, but should limit its area to that of its UIWindow.

Task-number: QTBUG-48225
Change-Id: Ia66ad6bba24d9d73a8263ad3f65b9dee9b8a1b37
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2017-11-22 21:27:43 +00:00
Stephen Kelly
a6d7f38791 QHeaderView: Simplify and fix layoutChange handling
A layoutChange indicates that anything can have moved to anywhere else,
including as a result purely of new items being added. It can also
indicate that items are removed.

The old code here incorrectly assumed that the section count remained
constant over this operation by setting the size of the oldSectionHidden
QBitArray - whose size is the size before the layoutChange operation -
and then calling setBit with model rows numbered after the layoutChange
operation.  As the two are not necessarily the same dimensions, this can
result in asserts from the setBit call.

Simplify the handling of layoutChanged entirely by clearing section
information, and using the QPersistentIndexes which indicate hidden
state to restore that state after re-population.

Task-number: QTBUG-53221
Change-Id: I3cda13e86b51b3029b37b647a48748fb604db252
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
2017-11-22 21:24:56 +00:00
Christian Ehrlicher
45a5f28aa4 QTreeView/Fusion style : Draw child indicator correct in RTL-mode
Fusion style did not honor direction option when drawing the child
indicator. This lead to a wrong rendering of QTreeView in right-to-left
mode.

Task-number: QTBUG-63396
Change-Id: I2d5de03d7c831e3caabcc9269617eecb9338f163
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2017-11-22 21:24:49 +00:00
Thiago Macieira
d813c66bfc Fix the build when AVX2 is enabled but __F16C__ isn't defined
If -mavx2 is used, __AVX2__ is defined, which enables the F16C code
after commit 280e321e52, but that was
wrong since we aren't allowed to use the F16C intrinsics with either
Clang or GCC (we can only do that with GCC 4.9 and Clang 4.8, and only
with an __attribute__ decoration).

With ICC and MSVC, we are allowed to use the intrinsics, but the
#include was missing.

[ChangeLog][QtCore] Fixed a compilation issue with qfloat16 if AVX2
support is enabled in the compiler. Since all processors that support
AVX2 also support F16C, for GCC and Clang it is recommended to either
add -mf16c to your build or to use the corresponding -march= switch.

Task-number: QTBUG-64529
Change-Id: I84e363d735b443cb9beefffd14b8ac1fd4baa978
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
2017-11-22 17:58:21 +00:00
Kevin Funk
b71b7461b0 CMake: Set SKIP_AUTOMOC/AUTOUIC where needed
Make sure we don't run into warnings for CMake 3.10

Task-number: QTBUG-63442
Change-Id: Ida004705646f0c32fb4bf6006036d80b1f279fd7
Reviewed-by: David Faure <david.faure@kdab.com>
Reviewed-by: Sebastian Holtermann <sebholt@xwmw.org>
Reviewed-by: Rolf Eike Beer <eb@emlix.com>
2017-11-22 13:51:30 +00:00
Mårten Nordheim
c3a5c482ef Fix tst_QSslSocket::waitForConnectedEncryptedReadyRead
... and unblacklist it.

It was blacklisted some years ago because it was failing too often.
It was failing because the ssl socket had already received and decrypted
all the data it was going to get, meaning the waitForReadyRead call was
just going to block forever.

Change-Id: Ia540735177d4e1be8696f2d752f1d7813faecfe5
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2017-11-22 13:50:09 +00:00
Andy Shaw
53f48fceee Start from the first visible item when doing a search
Since the first item in a treeview might be hidden, start from the
first visible item in the view when starting or wrapping round
during a keyboard search.

Task-number: QTBUG-63869
Change-Id: I202bea567c6d4484c3ffaf8a5f9af8ea2e13708d
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
2017-11-22 13:49:52 +00:00
Filipe Azevedo
048c380629 Code cleanup in QNAM
The private class already store a QNetworkConfigurationManager
 and networkSessionRequired so it's not need to compute them again
nor to instantiate temporary classes.

Change-Id: I1bbd9439afa70c950ed6ec3e4fc63ddae4a5b259
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2017-11-22 13:48:43 +00:00
Timur Pocheptsov
0f3c9782e6 tst_QNetworkReply::ioHttpRedirectErrors - fix a flaky test
This test became a real pain recently. A close look at the test shows
several problems (strangely enough, the failure can never be
reproduced on real machines, only on VM - Ubuntu and RHEL 6.6).
There are several asserts that are firing from time to time here and
there. They show that the logic in test is broken/incorrect. QNAM can
open several connections to a host, our test then incorrectly resets
its 'client' data-member and bad things can later happen after
'bytesWrittenSlot' executed (and deleted a socket). For example,
I can reproduce this scenario in every second run:

1. incoming connection -> client = socket(descriptor), connect to
   client's readyRead (s1)
2. incoming connection -> client = socket(descriptor), connect to
   client's readyRead (s2)
QNAM sends a request on s1. We reply on s2 (which is already wrong)
and call client->deleteLater(), which resets client to nullptr.
If QNAM sends something else on s1, we hit assert(!client.isNull()).

To avoid this, whenever 'sender' in any slot is different from the
'client', we use the actual 'sender' to reply. Another problem is this
weird and rather cryptic waitForFinish which is not needed in this
particular test since we wait for reply error, not 'finished'.

As it happened before - it's not clear if these two problems
were the cause of guaranteed fails on CI - an integration failed
~10 times in a row in the same test (not happening anymore though).

Task-number: QTBUG-64569
Change-Id: Id9aa091290350c61fadf1c3c001e7c2e1b5ac8f4
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
2017-11-22 13:47:30 +00:00
Tor Arne Vestbø
7ce71f0091 Disable -optimize-debug for Clang
It results in Xcode outputting a warning when debugging:

  [app name] was compiled with optimization - stepping may behave oddly;
  variables may not be available.

And the warning is correct, debugging is broken in this situation.

Likely caused by Clang treating -Og as -O1:

  https://reviews.llvm.org/D24998

Change-Id: I25d6bf1e65c81cc5be92b9847f7d5dd6754a0177
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
2017-11-22 03:18:37 +00:00
Tor Arne Vestbø
f92aa8e931 iOS: Add logging of window geometry/exposure
Change-Id: I6ffc7cd1dde4fadd3e952deabe9c3a1dbce7884d
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2017-11-21 23:16:46 +00:00
Tor Arne Vestbø
d8288d2b65 iOS: Make sure FBOs are cleaned up in the right QIOSContext
655687d84d shuffled things around, moving the logic to connect
to the window's destroyed signal from backingFramebufferObjectFor into
makeCurrent. Unfortunately backingFramebufferObjectFor was the one taking
care of recursing into the root context (when shared contexts were in
play), so the end result was that the root context were keeping track
of the FBO, but the leaf context was trying to clean up the FBO.

Task-number: QTBUG-56653
Change-Id: I80ed71a3dedeb7611b2aa7548d94b9fbe0e20763
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2017-11-21 23:16:44 +00:00
Tor Arne Vestbø
68733e307f qpa: Teach handleApplicationStateChanged about sync/async delivery
Using QWindowSystemInterface::SynchronousDelivery reduces the chance
that we are flushing other events before delivering the application
state change. Those other events may conclude that the application
is still active, while in reality it is not, and do bad things.

Change-Id: I738c162fac22d2cd18de1e080bcd2cda78ec3f77
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2017-11-20 23:31:46 +00:00
Gabriel de Dietrich
53f7c20cb5 Generic Unix Theme: Don't crash if D-Bus is not running
Change-Id: I215ef25fe943730ba8b1976695a04a4aa86638f1
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Dmitry Shachnev <mitya57@gmail.com>
2017-11-20 22:22:18 +00:00
Christian Ehrlicher
ba2f3a156e QTreeView: recalculate row heights in hide/showColumn()
When calling QTreeView::hideColumn() the row heights are not
recalculated. This can lead to rows which are unnecessarily high due to
hidden columns may contain large (e.g. multiline) content. The same
applies to showColumn() - there the row might be to small.
Hiding columns directly via QTreeView::header()->hideSection() is not
covered by this patch since QHeaderView has no way to inform about
newly shown/hidden sections.

Task-number: QTBUG-8376
Change-Id: I20b1198e56e403ab8cf649af76e5e2280821dd68
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2017-11-17 20:28:34 +00:00
Christian Ehrlicher
5c0a9fc532 QTableView: do not draw grid behind last section
QTableView::paintEvent() drawed the grid lines behind the last section
when the region to repaint contained rects which were completely
behind the last section.
This also lead to unnecessary repaints for cells inside rect.top() to
rect.bottom()

Task-number: QTBUG-60219
Change-Id: I42bb42bea504dfd3c92352ac5c65a43c246a05af
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2017-11-17 20:28:25 +00:00