Commit Graph

51609 Commits

Author SHA1 Message Date
Assam Boudjelthia
45daea19c3 Fix set*Field JNI template calls
The calls were trying to pass a JNIEnv* from a QJniEnvironment using
conversion operator which was removed, and weren't detected since they
are templates and were missing tests. This fix that and add test cases
for setField() and setStaticField() calls.

Pick-to: 6.1
Change-Id: I6e1e6b7f557bbc664248ad364c48d63f58b70756
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2021-05-05 16:28:27 +03:00
Assam Boudjelthia
afd7460aff Add new app permissions API under QCoreApplication
The API allows users to request and check the status of various
permissions. A predefined enum class of the common permission types
on different platforms is used to allow requesting permission with
a common code. Platform specific permissions are defined only on their
relevant platform. For permissions that are not predefined, they can
be requested via a string variant of this API.

This adds the Android implementation only.

[ChangeLog][QtCore] Add new API for handling app permissions with an
initial implementation for Android.

Task-number: QTBUG-90498
Change-Id: I3bc98c6ab2dceeea3ee8edec20a332ed8f56ad4f
Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2021-05-05 16:28:27 +03:00
Simo Fält
3969ef40cc Add instructions for Windows 10 on Arm config
Task-number: QTQAINFRA-3966
Change-Id: Ib8ac80a5b8aa5c88d9e5d0eaad9ba550cc2442f8
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Fathi Boudra
2021-05-05 16:28:27 +03:00
Joerg Bornemann
3886db82c6 Add -write-options-for-conan configure argument
Passing this configure argument will generate a JSON file that contains
information about configure options and features.

This file is used by Qt's conan recipes.

Fixes: QTBUG-92082
Change-Id: I2057ec8cbdb0a1ea198d7eeacb45f65bfa862d8a
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2021-05-05 16:28:27 +03:00
Bartlomiej Moskal
e5686b35f0 Android: handle ImEnterKeyType flag
Replace KEYCODE_ENTER to KEYCODE_TAB if IME_ACTION_NEXT or
IME_ACTION_PREVIOUS flag is set.

Before this change any of imKeyEntryType [1] was handled as default
return key. After the fix, event is changed to Tab or Backtab (if any of
mentioned flag is set)

[1] https://doc.qt.io/qt-5/qt.html#EnterKeyType-enum

Fixes: QTBUG-61652
Pick-to: 5.15
Change-Id: Ia27aa308fdae75bc17d1e892d17048c5afa3e2cb
Reviewed-by: Rami Potinkara <rami.potinkara@qt.io>
Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
2021-05-05 07:43:10 +00:00
Joerg Bornemann
33ac3cf766 Fix Windows build with CMake < 3.19
file(REAL_PATH) was introduced in CMake 3.19.

Use get_file_name_component(... REALPATH) instead that is available in
older CMake versions.

This amends commit b226e99c71.

Pick-to: 6.1
Change-Id: Ibb28ef757228e1a1176ff70c3ec57b7ca751a636
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2021-05-05 09:41:18 +02:00
Liang Qi
9f8d5bceb4 cocoa: move DEBUG_PASTEBOARD into logging category
Pick-to: 5.15 6.1
Change-Id: I8f49c030588122adff3c0eab4189bfa7e6aeff09
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2021-05-05 09:34:11 +02:00
Ivan Solovev
8161a9e5c0 QAbstractProxyModel: port to new property system
The biggest trick here is the getter (QAbstractProxyModel::sourceModel),
which is returning nullptr, while internally using a global
staticEmptyModel() instance.
This lead to inconsistency while binding to a proxy model without
source model. The bound object would point to staticEmptyModel()
instance, while sourceModel() getter returns nullptr.
To solve this issue a custom QBindableInterface is implemented.

Task-number: QTBUG-85520
Change-Id: I597df891c7e425d51b55f50ccbacabdfe935cbac
Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
2021-05-04 22:58:59 +02:00
Tor Arne Vestbø
0fb77f80b8 Blacklist and skip failing tests on macOS ARM
Task-number: QTQAINFRA-4431
Change-Id: I4ae47bb461634d524995077501b54322f6beccf3
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2021-05-04 22:58:59 +02:00
Timur Pocheptsov
3ab7449f12 Fix changes' doc
The name of attribute has a suffix 'Attribute' which was missing.

Pick-to: 6.1
Fixes: QTBUG-93416
Change-Id: I9ce96efb38caa03957ddbdb13a5e61767e8e74f1
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
2021-05-04 22:11:24 +02:00
Tor Arne Vestbø
f9f64cd344 Tweak naming of QT_OVERLOADED_MACRO variants
Add a _ suffix before the number of arguments, to improve readability
of the argument-specific functions.

Change-Id: I1dfc4f381450825dd143ece524bb10e117c09971
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-05-04 22:11:24 +02:00
Giuseppe D'Angelo
3a7d0e516b QPrintEngineMac: code tidies
In preparation for a change (operator&(enum, flags) producing a
QFlags, not an int), just go through operator&(flags, flags).
This removes the need for a cast to the _enum_ type (although it
requires a enum->flag conversion, which however makes perfect sense.)

Change-Id: I159ee14d894c10365f53ca378bcb18bcf3f89dff
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2021-05-04 16:21:50 +02:00
Mårten Nordheim
48931167fb tst_moc: fix returning-reference-to-local warning
Although the code is never executed compilers still throw a warning
because it's compiled.

Amends 12b8283f89

Pick-to: 5.15 6.1
Change-Id: Ib790d4bcb33c4b9f2a55a784b852275b59debde9
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-05-04 16:21:50 +02:00
Morten Johan Sørvig
07516c0811 Test at some Android DPIs in addition
Currently, we test at 1x, 2x, and mixed typical desktop
DPI values. Add android DPI values, with scale factors
in the 2.5 - 3.75 range.

This test currently uses 96 as the base DPI (and so
does the Android platform plugin), so we normalize
the values to use that base DPI.

Change-Id: I25b66f5e16d37c01758d5623b805e4141247a74a
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2021-05-04 16:21:48 +02:00
Morten Johan Sørvig
5882131592 Remove setting of Qt 5 high-dpi attributes
This test is for Qt 6 now.

Change-Id: I839c2733d505cb4119b1fe3ad85d3c8d94a6c964
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2021-05-04 16:21:48 +02:00
Edward Welbourne
517745fc9d Ensure setDateTime clears status also when short
Previously, if multiplication overflowed when trying to set the date
and time of a formerly short-form QDateTime, its status didn't get set
to reflect the failed validity check. Added a test that now correctly
detects that it's produced an invalid date-time on overflow, where
previously it produced a wrong valid date-time.

Change-Id: Id46ca34d1e32e9b9b0630f3723cefd1c13b5761e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-05-04 15:21:48 +01:00
Volker Hilsheimer
5e89c1406e Delete less-than operator for QKeyCombination
QMetaType relies on QTypeTraits to identify whether a type provides
operator<. Due to the the deprecated implicit conversion to int, this
results in several screens of deprecation warnings when using
QKeyCombination in a signal parameter or as a property type.

QKeyCombination has no ordering semantics (is Alt+F5 larger than
Control+Up?), so delete the operator.

[ChangeLog][QtCore][QKeyCombination] Potentially source-incompatible change:
the less-than operator for QKeyCombination has been deleted. Code relying
on the deprecated implicit conversion to int will no longer compile.
Use QKeyCombination::toCombined explicitly.

Change-Id: Ic8522b88d68063f74b5a5582c51aee8e18982331
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-05-04 11:52:38 +00:00
Fabian Kosmale
1e0be201c3 QUntypedBindable: Allow controlled access to internals
In declarative, we need direct access to the bindable's pointers. Enable
this via a internal only helper struct in qproperty_p.h.

Change-Id: I56e4622f570ff08f85f1161af608658ea510671e
Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io>
Reviewed-by: Andrei Golubev <andrei.golubev@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2021-05-04 07:57:46 +02:00
Mårten Nordheim
12b8283f89 Moc: parse trailing return type
Pick-to: 5.15 6.1
Fixes: QTBUG-71123
Change-Id: I1c3749f0892fddcc433c9afcb1d6d7c30c97c9d9
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-05-04 01:39:48 +02:00
Morten Sørvig
e3e070e87b iOS: Implement QIOSScreen::logicalBaseDpi()
logicalDpi() and logicalBaseDpi() should return the
same DPI on iOS, in order to make Qt not apply a scale
factor.

Accomplish this by overriding logicalBaseDpi() instead
of logicalDpi(). The default QPlatformScreen::logicalDpi()
implementation will then call logicalBaseDpi().

Pick-to: 6.1
Fixes: QTBUG-92579
Change-Id: I7a27cf61f0154cef32098069ab3dfb29ad6acf27
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
2021-05-03 21:49:05 +00:00
Thiago Macieira
f95d6bb09d tst_QProcess: increase wait time and remove ill-advised QCOMPARE
The QCOMPARE made dead code of a more verbose QVERIFY2 below

Change-Id: I26b8286f61534f88b649fffd166b67d8603280a7
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
2021-05-03 20:43:01 +00:00
Fabian Kosmale
ba561efa9d Add QUntypedBindable::metaType function
This enables checking the metaType of a QUntypedBindable in the public
interface.
In addition, work around an oversight that can only be fully addressed
in Qt 7: The metatype function pointer does not take a
QUntypedPropertyData * parameter. However, we need this functionality
for an efficient QBindable proxy implementation in declarative (which is
needed to implement interceptors there). To work-aronud this in Qt 6,
reuse the value getter and turn it into a metatype getter if the value
pointer is flagged.

Change-Id: Ia3cce08ea761fce57bce59e02212525b996f2fee
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2021-05-03 20:32:42 +02:00
Fabian Kosmale
98b4f4bc4d Q(Untyped)Bindable: Print warnings when operations fail
Instead of silently failing, we now print an explanatory warning to aid
with debugging.

Task-number: QTBUG-89512
Change-Id: I36dd2ce452af12d0523c19286919095e366bd390
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-05-03 20:32:42 +02:00
Ivan Solovev
d225c6afe7 QJniObject: add callStatic[Object]Method overloads for jmethodID
This patch extends the QJniObject::callStatic[Object]Method functions
with the overload which accepts a jmethodID parameter. This can be
convenient when the method id is already cached and you do not want
to query the method by its name and signature.

Task-number: QTBUG-92952
Change-Id: Ib0852a5a27da2a244ac63112784751ef9e32cfa5
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
2021-05-03 18:09:23 +02:00
Ivan Solovev
34f72ca52e QJniEnvironment: extend API
This patch adds some convenience methods to QJniEnvironment API:
* an overload of registerNativeMethods() that accepts jclass instead
  of const char *className.
* a findMethod() function is added to query a methodID of a static
  or nonstatic method by its name and signature.

Task-number: QTBUG-92952
Change-Id: Ib1bc892decea97e625c4822888b6183af6edd6dc
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
2021-05-03 18:09:23 +02:00
Friedemann Kleint
96d9cf8de4 uic: Fix font family code generation for python
Amend the code introduced by d8602ce58b
to generator correct code for Python.

Change-Id: I71fc9a1830d6bd591d32ce08002572c29f02a27f
Reviewed-by: Jani Heikkinen <jani.heikkinen@qt.io>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
(cherry picked from commit b2ebc64dd9914359fe8acf2bc9960e341e98cf80)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
2021-05-03 16:09:23 +00:00
Laszlo Agocs
c28e609ff4 rhi: gl: Sanity check vertex outputs and fragment inputs
Print a warning if the name for a given location does not match. This is
relevant only to OpenGL and only to < 330 GLSL versions: there the
location qualifier is simply not present in the actual shader code and
all matching is name-based. This leads to hard to discover problems in
Qt Quick ShaderEffects for instance, where providing a custom fragment
shader but using a built-in vertex shader is common, and one may be
tempted to use a name other than qt_TexCoord0 for the input variable in
the fragment shader. Unfortunately this breaks, sometimes silently, when
not having location qualifiers. (and we won't, neither in GLSL 120 or
150 which are the standard for Qt Quick)

Make this situation recognizable by printing a warning to the debug
output.

Pick-to: 6.1
Task-number: QTBUG-92500
Task-number: QTBUG-93370
Change-Id: I0d0bcc135e23a228783f7633f872e39c4e43bb93
Reviewed-by: Christian Strømme <christian.stromme@qt.io>
2021-05-03 16:10:36 +02:00
Friedemann Kleint
21b3b54193 QSqlTableModel::orderByClause(): Quote the table name
This ensures correct handling of names with special characters.

Pick-to: 5.15 6.1
Fixes: QTBUG-92584
Change-Id: I95c7c54d9c7ee00b221a55f3d07ef1ec3a3bd217
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-05-03 14:10:36 +00:00
Volker Hilsheimer
18f5b83e97 Document that a toplevel window QSizeGrip doesn't get rendered on macOS
Amends b8947e9194 which removed the grip's
rendering unless they are in a QMdiSubwindow. This was a deliberate
choice to comply with the macOS HIG. Rather than putting in another
widget attribute, document that another style can be used.

Fixes: QTBUG-90945
Pick-to: 6.1
Change-Id: Id227fd31d8bafaaab7005e5ff5340da96c0f65b3
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2021-05-03 15:04:47 +02:00
Kai Köhne
16a1ba69a6 Disable spurious MSVC warning C4273 in Qt Gui, Qt OpenGL
For optimized/release builds, cl 19.28 produces some false positive
"potential divide by 0" warnings even for code where no valid code path
can lead to such a division.

Fixes: QTBUG-92940
Pick-to: 6.1
Change-Id: I461f9104d7b9dc2d74839bf30bebb2b9d4cf2db3
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
2021-05-03 13:04:47 +00:00
Morten Johan Sørvig
b5ceba0128 Extend QT_SCREEN_SCALE_FACTORS test
Test the name=factor format and various incorrect spec
strings. We expect that the screen DPI is used if the
scale factor specification is incorrect.

Change-Id: Ia990e70cf71e370dd2bb4b1047a101dfe9e59cb0
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2021-05-03 13:33:43 +02:00
Morten Johan Sørvig
51e2a64ed9 Parse QT_SCREEN_SCALE_FACTORS spec only once
Move parsing to initHighDpiScaling() and store the parsed
factors in a vector. The factors are later applied in
updateHighDpiScaling() where the factor list is compared
to the screen list.

Change-Id: I59fc67b84932dbe69868a3683686a91e51333104
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2021-05-03 13:33:43 +02:00
Joerg Bornemann
d41ef4f741 Add ABI suffix to .prl files for Android
The libraries already contain the ABI suffix, and the .prl files should
too. This is a requirement for ABI-stitching of Qt Android builds.

Fixes: QTBUG-90023
Change-Id: Ib2a7b3119ace14c8542242fc45f42648840d053a
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2021-05-03 13:33:43 +02:00
Joerg Bornemann
b0e96ee181 Update the comment in QtFinishPrlFile.cmake
Clarify that OUT_FILE is not the final .prl anymore and where we get the
path of the final .prl from.

Change-Id: I4563c6ef1026bc0646e3ac9ab2fac49e426ca07f
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2021-05-03 13:33:43 +02:00
Pekka Gehör
2262a9cd2d Android: Fix Application becomes unresponsive issue
Block key events until the plugin is running.

Fixes: QTBUG-67944
Pick-to: 5.15 6.1
Change-Id: Iea47f2e94d850141834a7e8fc26218be2cacf660
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
2021-05-03 08:48:57 +03:00
Giuseppe D'Angelo
3e2e0dde47 QFlags::setFlag: don't go through Int, go through QFlags itself
Avoid a "detour" outside QFlags' type safety: operator~ is defined
on QFlags already, use that one.

Change-Id: Iedd07d1652b8f92e3881298ceafcd5c761346bb0
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-05-03 02:54:10 +02:00
Thiago Macieira
e4ed47ef4a QCoreApplication::applicationFilePath: add ELF auxval support
This implements getting the executable file name for FreeBSD. Linux has
a similar functionality (but called AT_EXECFN), but the /proc/self/exe
trick is actually better: it returns a full canonical path instead of
the argument passed to execve(), and it follows a rename of the
executable.

Change-Id: I7a386ad4f0cb4e2ba629fffd16789acda415213f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
2021-05-02 22:21:00 +00:00
David Faure
831aea1ce1 qdbus: add support for "aay" (QByteArrayList)
(I wish these common mappings were centralized though, so that
annotations in the XML file wouldn't be needed)

Pick-to: 6.0 6.1 5.15
Change-Id: Ie3e8731e44b6e0338c8a044408c34160cf0a3a1e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-05-02 22:00:43 +02:00
Giuseppe D'Angelo
3c16330c2d QLocalSocket: declare operators for the SocketOptions flag
The flag existed, without the operators.

Change-Id: I386f76b358422fbfc3fbd7b227901803ec27202d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-05-02 20:25:41 +02:00
Giuseppe D'Angelo
7507afccee QFlags: streamline some macros
There's little point at keeping the separate Q_DECLARE_INCOMPATIBLE_FLAGS
macro, only to invoke it exactly once (from the expansion of
Q_DECLARE_OPERATORS_FOR_FLAGS). Besides, Q_DECLARE_OPERATORS_FOR_FLAGS
already had some "incompatible" operators in its expansion (the
deleted arithmetic ones), so adding the "incompatible" ones in there is
consistent.

Change-Id: I591d57af8eec5b03ecaa7a3b0de23a967b13f7a5
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-05-02 20:25:41 +02:00
Giuseppe D'Angelo
99e95a2cc6 QLocalSocket: fix inclusions in namespaced builds
An include statement appeared after opening the Qt namespace, thus
injecting symbols in there. Move it outside.

Change-Id: I8e95e821b36ad4e4ceed5b0645bf8ebf7e531e06
Pick-to: 5.15 6.0 6.1
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-05-02 20:25:41 +02:00
Giuseppe D'Angelo
36cf5d905a QFlags: remove the doc-only declaration of copy operations
qdoc is now able to recognize the special members automatically.

Change-Id: I773d94d9e622e67340f3acdbe8bff66143ee1aaa
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-05-02 20:25:41 +02:00
Giuseppe D'Angelo
79d7801388 QFlags: kill Q_NO_TYPESAFE_FLAGS
The macro is undocumented and unused.

Change-Id: I5c09f4e0e2d41e13d2678e2936e0d0e39ed69639
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-05-02 20:25:41 +02:00
Giuseppe D'Angelo
e2145a47fc QUrl: code tidies
Change some casts of enumeration/flag types from int to uint.
In fact, the enumerations (and flags) in question are *defined* to
be backed by unsigned int.

Change-Id: I757ded61a26fe979deeaa1e5a524478102960ffe
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-05-02 17:28:56 +02:00
Giuseppe D'Angelo
6ab8ea2d58 QRandom: enable a check also on MSVC
We require MSVC 2019 these days, so we can actually check for
constexpr initialization.

Change-Id: Idc14b785d51c8baaa0bca0ec7dd2e8a85a7e2092
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-05-02 11:52:30 +02:00
Giuseppe D'Angelo
6351b5433d QRandom: drop a usage of std::is_literal_type
It's deprecated/removed, and indeed doesn't check anything that it's
not also already being checked by the previous line.

Change-Id: Ic80ca43f390dd989ced69f196efa7313069e7c6d
Pick-to: 5.15 6.0 6.1
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2021-05-02 11:52:12 +02:00
Thiago Macieira
d08d456844 cmake: FreeBSD has DF_ORIGIN support
Pick-to: 6.1 6.0
Change-Id: I755911ae7d0341f49039fffd167afce7fe6b2b38
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2021-05-01 16:02:31 -07:00
Thiago Macieira
19fa58447e Revert "Include qsimd.cpp in bootstrap build"
This reverts commit 9268cb8085. That was
done in the mistaken assumption that the bootstrap library needs the
fast hashing algorithms. It doesn't, since it's only used for tools that
need deterministic output anyway.

This fixes the build on x86 where the compiler is enabling rdrand by
default (Ivy Bridge systems, but also -march=haswell and the GCC 11
-march=x86-64-v3):

qsimd.cpp:750:37: error: redefinition of ‘qsizetype qRandomCpu(void*, qsizetype)’
  750 | QT_FUNCTION_TARGET(RDRND) qsizetype qRandomCpu(void *buffer, qsizetype count) noexcept
      |                                     ^~~~~~~~~~
In file included from qsimd.cpp:44:
qsimd_p.h:354:25: note: ‘qsizetype qRandomCpu(void*, qsizetype)’ previously defined here
  354 | static inline qsizetype qRandomCpu(void *, qsizetype) noexcept
      |                         ^~~~~~~~~~

Change-Id: I755911ae7d0341f49039fffd167afc7540bf0dd6
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2021-05-01 18:55:42 +00:00
Thiago Macieira
26a7c53009 QHash: disable the AES based one on the bootstrap library
The bootstrap library doesn't need it. All bootstrapped tools are
expected to produce deterministic output, given the enforced seed of 0:

 #ifdef QT_BOOTSTRAPPED
     // the seed is always 0 in bootstrapped mode (no seed generation code),
     // so help the compiler do dead code elimination
     seed = 0;
 #endif

Change-Id: I755911ae7d0341f49039fffd167afc934ff1c9e1
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2021-05-01 11:55:42 -07:00
Shawn Rutledge
c8736e8e61 Add grabber context pointers
In Qt Quick we now need to keep track of which QQDeliveryAgent is
responsible when a point is grabbed, either passively or exclusively.
When we re-deliver to that grabber, we need to do it via the same agent,
so that the same scene transform is used, and the grabber will see the
event in the correct coordinate system.  It's easier to track this
mapping here instead of in a separate map in Qt Quick.

(This is an alternative to 40330b8f0a:
it was not possible to use QFlatMap, because we need to keep the passive
grabbers in the same order as they were added.  We don't use a QList of
structs, because QPointerEvent::passiveGrabbers() needs to return a
QList of just the grabbers, and it's not as efficient to construct that
list in the accessor.)

Change-Id: I457114f816736749d2ea5ee48fa03524eb93d2d0
Pick-to: 6.1
Task-number: QTBUG-92944
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
2021-05-01 19:40:36 +02:00