Commit Graph

53178 Commits

Author SHA1 Message Date
Laszlo Agocs
6cdf95a970 rhi: Include resource count in srb layout compatibility checks
Relevant for Vulkan, given that descriptorCount is part of
VkDescriptorSetLayoutBinding, meaning two srbs with arrays of
SampledTextures should only be reported as compatible if the
array size matches.

Also reduces the prealloc size for the VLAs. For Qt Quick even a
lower number would be sufficient, but we still keep the number
something fairly high in order to play nice with Quick3D.

Pick-to: 6.2
Change-Id: Id92b7c09b051ebe54b1fa2bf4ba78950fe60ba27
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
2021-09-03 17:14:59 +02:00
Milla Pohjanheimo
aac1858920 Add binary compatibility files for 6.1
Binary compatibility files added.

Change-Id: Ie575c774b13b3eae24412e535fa68be8c0ff5fb6
Reviewed-by: Jani Heikkinen <jani.heikkinen@qt.io>
(cherry picked from commit d4b4bed8b825525e61bac9fe2843d18c933625a9)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
2021-09-03 13:41:25 +00:00
Ievgenii Meshcheriakov
19a48b8545 unicode: Regenerate qunicodetables{.cpp,_p.h}
Run unicode utility to regenerate the Unicode tables. This reduces
size of the IDNA mapping tables. Adjust the QUrl client code to use
the new API.

Task-number: QTBUG-85323
Change-Id: Iaa8d6932e611f7aa4009a3fae2972de87b875cf8
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-09-03 14:43:16 +02:00
Ievgenii Meshcheriakov
5f3f073126 unicode: Build IDNA map superstring greedily
This slightly reduces memory required for mapping tables:

    uncompressed size: 1146 characters
    consolidated size: 904 characters
    memory usage: 47856 bytes

Task-number: QTBUG-85323
Change-Id: Ic960789e433e80acf1a4e36791533a1c55a735c8
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-09-03 14:43:16 +02:00
Ievgenii Meshcheriakov
2d78b71fc6 unicode: Pack 2 QChar's into one entry for IDNA mapping
Store up to 2 QChar's for mapping values inside the mapping
table itself. This reduces the size of the superstring for
other mapping values.

results:
    uncompressed size: 1146 characters
    consolidated size: 1001 characters
    memory usage: 48050 bytes

Task-number: QTBUG-85323
Change-Id: I922a6d2037551d0532ddae1a032ec1a9890f40a7
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-09-03 14:43:16 +02:00
Ievgenii Meshcheriakov
ca1eeb23fa unicode: More compact IDNA mapping tables implementation
This implementation stores mapping that are 1 QChar long
inside the mapping tables, the longer mappings are stored as
an offset and length pairs pointing into the common superstring
of all such mapping values.

Size comparison with the existing implementation follows.

old:
    max mapping length: 6
    memory usage: 103608 bytes

new:
    uncompressed size: 3250 characters
    consolidated size: 2367 characters
    memory usage: 50782 bytes

Task-number: QTBUG-85323
Change-Id: I9f2e32438dd463457e0fcd783136bb17145e27a8
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-09-03 14:43:16 +02:00
Ivan Solovev
e300fc9204 Make tst_QLocale::TransientLocale succeed at changing system locale
It was previously calling setlocale(), which makes no difference to
the Unix backend for the system locale, since that's based on
environment variables (that would normally be used to get default
values for the various setlocale() categories, but only the first time
each is asked for). So, on Unix, set the environment variable, too.

It's also necessary to instantiate a QSystemLocale instance
transiently to trigger a refresh of the system locale data.

Pick-to: 6.2
Change-Id: If92e44053f9021e96c814f4b289f4fadaa7027e0
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
2021-09-03 14:00:53 +02:00
Alex Trotsenko
340131b4be QWindowsPipeWriter: suppress a warning on unexpected peer disconnection
The other side can close the pipe at any time independently of us, so
ignore the ERROR_PIPE_NOT_CONNECTED error code if the write operation
failed.

Change-Id: I4f7ccd73c19ca2dd24fa1c9f33b5f60541a7521d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
2021-09-03 09:31:42 +03:00
Liang Qi
5c779f207f xcb: add manual test for xrandr scale
This amends 9a4c98e556.

Change-Id: Ief86d141efa8f87d624c6ba935cb4d9c0b2ead0f
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
2021-09-02 21:57:02 +02:00
Morten Johan Sørvig
8c2fda1ef5 Test QWindow close() behavior
Verify that closing a QWindow using either the close()
API or a close event works as expected, and that the window
can be re-created. Also test QWindows with child windows.

Task-number: QTBUG-46701
Change-Id: I4c12452ff58e1233536c2d6932e72cf924d8ed74
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2021-09-02 20:34:48 +02:00
Volker Hilsheimer
7ba75d088c QWidget: close the QWindow in QWidget::close
We want to close the window, end full screen mode on macOS, and free
platform resources. This is all done by QWindow::close. QWindow::close
closes the platform window, triggering a closeEvent to QWidgetWindow,
which then calls QWidgetPrivate::close_helper.

This way, closing a window via QWidget::close, QWindow::close, or
interactively by the user are all equivalent.

The QCloseEvent generated by the widget needs to be spontaneous for
window-system generated events (i.e. the user clicked the close button),
and non-spontaneous if the window closes because of a call to
QWindow::close. To keep track of whether the event originated in an
explicit call to QWindow::close, add a boolean to the QWindowPrivate.

Add a test case that verifies that the window resources is destroyed,
and that events are delivered as they should.

Done-with: Morten Johan Sørvig <morten.sorvig@qt.io>
Fixes: QTBUG-46701
Pick-to: 6.2
Change-Id: Iacb6a2c8d5e880b16b0c8f0c9257ed94bed36f5b
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2021-09-02 20:34:48 +02:00
Talent Gc
f10ec04a6c SQL browser example: fix typo
Both 'First name' and 'Last name' are two words, therefore
the column names should be spelled 'FirstName' and 'LastName'.

Fixes: QTBUG-96123
Change-Id: Iaf58442eba0bc5eb63dcde83ecdebdc4a3c658a5
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
2021-09-02 15:45:16 +00:00
Mårten Nordheim
05c9894330 QNetworkAccessCache: Style fixes and move asserts
Change-Id: I300d2525d9987737697e2cc6a326be19554902c8
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-09-02 16:57:42 +02:00
Mårten Nordheim
a253bec500 QNetworkAccessCache: Port to QDeadlineTimer
QDeadlineTimer is semantically more correct than comparing timestamps to
'now'.

Change-Id: I15d9654af2886499392e6409d22f802203aca18d
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2021-09-02 16:57:42 +02:00
Mårten Nordheim
3a7d6767e9 QNetworkAccessCache: move debug logging to specific ifdef
Instead of for any debug output.
Since QTestLib cuts off output after X messages we shouldn't add these
by default.

Another option would be categorized logging, but QNAC should not be very
interesting for 'outside' users

Change-Id: I4c2c2a68ca4962476bfecd679f3229ccf3403aee
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-09-02 16:57:42 +02:00
Mårten Nordheim
8460a55d32 QNetworkAccessCache: Remove the ctor and init member variables in class
Change-Id: Ic7ce41679d89b496413ef13e6e917bf506b2405d
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2021-09-02 16:57:42 +02:00
Mårten Nordheim
3a8f9286fc QNetworkAccessCache: Rename first and last node
'oldest' and 'newest' to me make me thing of 'least recently inserted'
and 'most recently inserted', which is what they used to mean.
But now the expiration can be set per-request so the semantics don't
work anymore.
So, rename to 'nextExpiringNode' and 'lastExpiringNode'. Also rename the
node member elements "older" and "newer" to the more generic "previous"
and "next".

Change-Id: I582267d09c60c68396e4201e4a20185bbf0942e2
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2021-09-02 16:57:42 +02:00
Edward Welbourne
7403561f21 Remove a redundant check
Missed in a recent fix to QTimeZonePrivate::dataForLocalTime(), but
noticed during picking back to 5.12

Pick-to: 6.2
Change-Id: I63964952150fedf857b7aef12dfc866097d2e2d1
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
2021-09-02 16:35:12 +02:00
Edward Welbourne
f645bb8880 Replace implementation-specific zero test with plain comparison
Various double-to-string converters carefully omit the sign from -0.0,
for which they need to test whether the double is zero. This was
tested by a function that looked at the bytes of the double in an
endian-specific way. Packaging a comparison to zero in a function
seems to avoid the compiler warnings over double-comparison, so retain
the function but make it simpler. The only available benchmark
(QString's number_double benchmark) consistently shows a negligible
improvement in performance.

Change-Id: Id994177e21e4770ced904881d7e84a95cb727605
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-09-02 16:35:12 +02:00
Craig Scott
f266381b1b Clean up output target handling left behind by earlier changes
Previous work removed the no-longer-used code path that could add
targets from qml compiler features. The variable that code path would
populate was not fully cleaned up in that removal. Clean it up now and
move the variables related to output target handling closer to the
only remaining area where they could be generated.

Also ensure that we set the variable named by OUTPUT_TARGETS even if
isBinary ends up being true. We should explicitly set that variable
to an empty string in that case.

Amends 363df5cd70

Pick-to: 6.2
Change-Id: I17de9788b390aac9a7aedb29ab9bdfee99c305af
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2021-09-02 20:52:22 +10:00
Fabrice Fontaine
035dc537be Fix build on riscv32
riscv32 fails to build because __NR_futex is not defined on this
architecture:

In file included from thread/qmutex_linux.cpp:45,
                 from thread/qmutex.cpp:804:
thread/qfutex_p.h: In function 'int QtLinuxFutex::_q_futex(int*, int, int, quintptr, int*, int)':
thread/qfutex_p.h:116:30: error: '__NR_futex' was not declared in this scope; did you mean '_q_futex'?
  116 |         int result = syscall(__NR_futex, addr, op | FUTEX_PRIVATE_FLAG, val, val2, addr2, val3);
      |                              ^~~~~~~~~~
      |                              _q_futex

Pick-to: 6.1 6.2
Fixes: QTBUG-96067
Change-Id: Ib6a9bcc496f37e69ac39362cb0a021fccaf311f5
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-09-02 09:59:33 +00:00
Alex Trotsenko
5d68858ba7 QLocalSocket/Win: fix waitFor...() functions for write-only socket
There were several issues with the socket state checking when the pipe
reader is not running:

  - the number of object handles in the WaitForMultipleObjectsEx()
    call might have been zero;
  - a call to the waitForDisconnected(-1) might have hung;
  - we did not perform a loop iteration for the waitFor...(0) calls,
    so disconnect detection was unreliable.

These issues are related to the same code, so they don't seem to be
addressable separately.

Change-Id: I3bca872bb4191e6a7d38a693d81f7981af7fe145
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
2021-09-02 08:47:11 +03:00
Liang Qi
9a4c98e556 xcb: support xrandr(1.5) monitor setup
More information about monitor in xrandr 1.5, see
https://keithp.com/blogs/MST-monitors/

Since this change, screen is logical instead of physical.

If xrandr 1.5 and later is installed, Qt screen info will get
from xrandr monitor object instead of xrandr output if only have
1.2 to 1.4.

Users can manipulate monitor as they want, for example, a
combination for two physical screens, half of one screen and etc.

Didn't have chance to access MST monitors, but it should work
if xrandr monitor object was created automatically.

[ChangeLog][xcb] Qt screen info will get from xrandr monitor
object if 1.5 is installed.

Fixes: QTBUG-65457
Change-Id: Iad339cc0d4293b2403b4ef6bf6eb770feb3e685f
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
2021-09-01 20:32:04 +02:00
Thiago Macieira
f3743073a7 qstrnlen: micro-optimize further
This is the kind of loop that the autovectorizer is pretty good
at, but this is really just a type of memchr, so help dumber
compilers and build modes without vectorization.

Drive-up fix the style of the test code.

Change-Id: Ie72b0dd0fbe84d2caae0fffd16a022a35fa24c17
Reviewed-by: Ievgenii Meshcheriakov <ievgenii.meshcheriakov@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-09-01 11:32:03 -07:00
Mårten Nordheim
9258c50936 tst_QNetworkReply: Remove and suppress one debug message
There's not much context to the URLs being printed, so remove the
message. And suppress the message coming from the MiniHttpServer

Change-Id: Ie2025ac717657ed0f2f0163bd0af22e12a49b30f
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2021-09-01 18:03:15 +02:00
Mårten Nordheim
4757b93b0e Test QNetworkAccessCache insertions with varying expiry times
The insertions are sorted by when they expire. So, we test the various
orders to insert entries.

Fixes: QTBUG-95959
Change-Id: I1e8d7f4c77dce5eae3d4bfa5101f296c3eea1961
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-09-01 18:03:15 +02:00
ChunLin Wang
ca69e5aeef Fix QListView assert when the last row is moved in IconMode
After the last row is moved, 0 will be returned when obtaining
row and column data. At this time, QListView::doitemslayout will
not call d->doitemslayout, so the QBspTree data structure will
not be cleaned up, leaving a stale tree structure behind. This
will trigger an assert during paintEvent handling if QListView is
set to IconMode

In QListView::ListMode the test for a valid model index doesn't
use an assert.

Call QListViewPrivate::clear explicitly if the column count is 0
so that the QBspTree and other data structures are cleared.

Add a test case that simulates this scenario by implementing a
model that returns a 0 column count for an index after the model
structure was changed through a move of rows.

Done-with: Volker Hilsheimer
Fixes: QTBUG-95463
Pick-to: 5.15 6.1 6.2
Change-Id: I36419be5459b8ced930c619f538482ea1db4ad03
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
2021-09-01 16:03:15 +00:00
Edward Welbourne
38ec2c830b qlocale_win: Fix non-standalone month names
We have previously been using the standalong (nominative) month names
both when asked for that and when asked for the plain (genitive) month
name, probably because there was no LCTYPE value for the
latter. However, MS's docs for the standalone values do contain a
comment telling us how to get the genitive names.

Rename the old monthName() to standaloneMonthName() and add a
monthName() that calls GetDateFormat() suitably, as described by the
MS doc.

Pick-to: 6.2 5.15
Fixes: QTBUG-92018
Fixes: QTBUG-86279
Change-Id: I27f63198c3a15b792683f476d2019078b0860f99
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
2021-09-01 17:56:46 +02:00
Edward Welbourne
6da648ad83 Add a QLocale(QStringView) constructor
Only a few more internals just needed to change to take QStringView,
to connect up the constructor with internals already long since
converted.

[ChangeLog][QtCore][QLocale] Added QLocale(QStringView) constructor.

Change-Id: Iec31391e6168f333b4b6fc633c3d7d01872f83b3
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
2021-09-01 17:11:44 +02:00
Eirik Aavitsland
dc65267ad8 When clearing QPixmapCache, stop its flushing timer
No need for timer event to reduce cache size when it is already empty.

May also avoid the "Timers cannot be stopped from another thread"
warning at exit, if the global cache object is then deleted by another
thread.

Fixes: QTBUG-96101
Pick-to: 6.2 5.15
Change-Id: Id1aeecfbb43a25a887ebd5cc7242749a74290bb0
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
2021-09-01 17:11:44 +02:00
Edward Welbourne
e3d5d363f7 Avoid senseless duplication of code in a testlib selftest
Delegate repeated tasks to functions - DRY !

Change-Id: I8973d2b9cd1f7d0fe94a9ae4aebcff434821e210
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
2021-09-01 17:11:43 +02:00
Eirik Aavitsland
a6a3b1e79c Update bundled libjpeg-turbo to version 2.1.1
[ChangeLog][Third-Party Code] libjpeg-turbo was updated to version 2.1.1

Pick-to: 6.2 5.15 5.12
Change-Id: I22a273018229aa35a175f9e903fa605a3eb55c32
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
2021-09-01 17:11:43 +02:00
Edward Welbourne
bac150f056 Add a repeated-failure selftest for testlib
This mimics the effects of test-code delegating checks to other
functions, which can lead to repeated failures. The failing test
should only contribute one to the total of failed tsts.  Drive-by:
correct an existing test's reporting of its own name.

Task-number: QTBUG-95661
Change-Id: I370fd2aee378d9fdd35826f0d11677483c60423d
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
2021-09-01 17:11:43 +02:00
Ivan Solovev
313de93b1d QDoubleValidator: fix NaN check in validateWithLocale
We can't really compare two NaN's. Should use qIsNaN() for that.

Pick-to: 6.2
Change-Id: Ia514cabe65cfcdeafb39cab91ecdb66f8fae725c
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-09-01 17:11:43 +02:00
Mårten Nordheim
81a9335c65 Fix documentation of QNetworkAccessBackend
The classes themselves were not documented, so...:

Add some documentation for QNetworkAccessBackendFactory.
Add some overall class docs for QNetworkAccessBackend.

The class docs were marked \internal (because they mostly are).
I don't think we yet have a defined way to handle semi-private APIs but
having them be marked \internal and leaving the documentation in source
seems fine (and was what someone suggested a while back).

Add documentation for pure virtual functions which were overlooked.

Pick-to: 6.2
Fixes: QTBUG-88774
Change-Id: Id7fe18ec92372abb96540cd29543608f87ec862e
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-09-01 14:51:29 +00:00
Morten Sørvig
81a7344e1d Port to QImage and QPixmap deviceIndependentSize()
Replace the “size() / devicePixelRatio()” pattern with
a call to deviceIndependentSize().

Change-Id: I9d9359e80b9e6643e7395028cd43e3261d449ae7
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2021-09-01 15:24:05 +02:00
Ievgenii Meshcheriakov
4e460aa3f7 tests: Add test for UTS #46 implementation using Unicode data
The new test is called tst_qurluts46. It verifies QUrl::{to,from}Ace()
functionality using the data from IdnaTestV2.txt supplied by Unicode.

The file was downloaded from
https://www.unicode.org/Public/idna/13.0.0/IdnaTestV2.txt

Task-Id: QTBUG-85371
Change-Id: I4c6a4942ef6018dafc90cb84ef73f6b2614566d7
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-09-01 14:15:45 +02:00
Edward Welbourne
f98d9aa9da Refine QLocale constructor documentation
Fix a typo and swap two sentences to give a clearer reading.

Pick-to: 6.2
Change-Id: I4a24ad5ba2e022edd121eb686de3638af2c242a6
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
2021-09-01 11:27:42 +02:00
Edward Welbourne
b656cea5de Fix corner case in QTimeZonePrivate::dataForLocalTime()
If the local time for which we want data is after the last known
transition, the two transitions we get to bracket it are the last
known and an invalid one. The code checked the former was valid, but
neglected to check the latter, leading to nonsense arithmetic later in
the function. In this situation we unequivocally want the last known
transition, so the problem is easily solved.

Fixes: QTBUG-96152
Pick-to: 6.2 6.1 5.15 5.12
Change-Id: I6fc830ce538e8a572093cd8dfe832e10689bf904
Reviewed-by: Andrei Golubev <andrei.golubev@qt.io>
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
2021-09-01 11:26:54 +02:00
Edward Welbourne
5598a15fe7 Mark QLocale's private functions [[nodiscard]]
If only to make the exceptions stand out, so we can see which ones
only exist for their side-effects.

Change-Id: I90b649d4da09f57ab986f29c577993dd12e34721
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-09-01 11:16:52 +02:00
Lorn Potter
375c7c47ff wasm: fail when configuring for wasm and EMSDK is not found
Pick-to: 6.2
Change-Id: Ic7fb933d8c2b42c3ba84a3b5a6c89a808d971bd1
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2021-09-01 08:02:08 +10:00
Edward Welbourne
52473c7bf1 Use QByteArrayView::toInt() instead of duplicating its implementation
The code in qEnvironmentVariableIntValue() to parse the text as an int
can now delegate it to QByteArrayView, so that keeping in sync with
QByteArray::toInt(), as a comment requested, is now automatic.

Change-Id: I09a6b7245ecd02f39a850a4ce187f86709282e8c
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-08-31 20:37:14 +02:00
Ievgenii Meshcheriakov
c8612b156d tst_qstringapisymmetry: Re-enable trim_trimmed_QByteArray
The testcase was disabled with no explanation in
2766322de3 but seems to work fine.

Change-Id: Ibc22a4ffb756604e22c1f2cf1165919c1d7f1212
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-08-31 19:45:52 +02:00
Mårten Nordheim
5ad75eda0c QNetworkAccessCache: Another fix to the linked list insertion
When inserting between two nodes the "previous" node's "newer" was
forgotten and not updated. So every node's "newer" would point to the
"newest" node.

Change-Id: I5b0df8812be5f7f62b3ae363e4c78f582e0e5c43
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-08-31 17:54:30 +02:00
Fan RuiJie
586d9e6013 Fix text ellipsis not implemented in Tibetan
The original code checks the existence of an ellipsis character first.If
this does not exist (glyph == 0,which is an invalid glyph index), then
it falls back to looking up '.'. But in the Tibetan environment,the
glyphIndex('.') also returns 0, so that it simply doesn't add any form
of "...", and cuts the text instead.

If both the attempts at getting something from the main font fails,
we can do a third pass on the "multi" font engine.

Fixes: QTBUG-95942
Pick-to: 6.1 6.2
Done-with: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
Change-Id: I251de3fe92e19be0462c58c2059ecf7d354bfbb0
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2021-08-31 14:53:45 +00:00
Yang Yuyin
6e9cae0b77 QFileDialogComboBox: member variable is not initialized
initialize d_ptr in the constructor

Pick-to: 6.2
Change-Id: I5a8062dd0a81023e6c1a5858bb8603d279cdbcee
Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
2021-08-31 13:18:15 +02:00
Craig Scott
08180e76e6 Ensure versionless wrappers do not introduce a new variable scope
Using function instead of macro prevented the wrappers from being able
to pass back any variables set in the wrapped function. In some cases,
these variables were being explicitly passed back to the caller, but
that isn't needed if you just make each wrapper a macro. This also
makes things more future-proof because any newly introduced output
variables will work without having to update the wrappers.

Task-number: QTBUG-96121
Pick-to: 6.2
Change-Id: Ic4486de668694c06b47e466587b2cdcb969ea047
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2021-08-31 17:05:15 +10:00
Robert Löhning
d54d91c0ad Fuzzing: Discard more logging output from QSslCertificate
When linked to OpenSSL, qt.tlsbackend.ossl will log.

Change-Id: I6f0e3c3e6af73b29cff93b8efe39933e5b36d493
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
2021-08-30 22:05:49 +02:00
Volker Hilsheimer
6e2a5312db Revert "Forward touchEvents to children inside QGraphicsProxyWidget"
This reverts commit 1ecf2212fa.

The fix is not correct after all. TouchBegin goes to the correct
widget with the fix, but following TouchUpdate and TouchEnd events
now go to the viewport, as QApplication::translateRawTouchEvent always
gives precedence to the widget that Qt recorded to be the touch
grabber, which is the viewport. This results in infinite recursion,
as the proxy widget trying to send the touch events to the embedded
widget (expecting that translateRawTouchEvent will split it up) ends
up sending the events back to the viewport.

Leave the added test case as QEXPECT_FAIL, reactivate the (never run,
hence unnoticed) test that the fix broke.

Pick-to: 6.2 6.1
Task-number: QTBUG-45737
Task-number: QTBUG-67819
Change-Id: I4810affb3cd066743ae94ab7beb2f0c06b60d211
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
2021-08-30 19:34:50 +00:00
Assam Boudjelthia
d9381bc7c3 Enable building and uploading tests for Android targets if tests enabled
Enable building and uploading test artefacts for all modules in case
tests are enabled.

Pick-to: 6.2
Task-number: QTBUG-88846
Change-Id: I30832820dea348187b517e170fa1c5266db85604
Reviewed-by: Toni Saario <toni.saario@qt.io>
2021-08-30 20:51:47 +03:00