For people running this test who are burdened with a broken DNS server
and for whom the check added in the previous commit fails, skipping the
test.
Incidentally, this is useful for developing QDnsLookup itself, because
some otherwise-reasonable servers are known to fail for some queries.
For example, dnsmasq doesn't like queries of type ANY:
SKIP : tst_QDnsLookup::lookup(any-a-single) Server refused or was unable to answer query; a-single type ANY: Server failure
SKIP : tst_QDnsLookup::lookup(any-a-plus-aaaa) Server refused or was unable to answer query; a-plus-aaaa type ANY: Server failure
SKIP : tst_QDnsLookup::lookup(any-multi) Server refused or was unable to answer query; multi type ANY: Server failure
Now I can get it to pass with QTEST_DNS_SERVER='[2001:4860:4860::8888]':
PASS : tst_QDnsLookup::lookup(any-a-single)
PASS : tst_QDnsLookup::lookup(any-a-plus-aaaa)
PASS : tst_QDnsLookup::lookup(any-multi)
Note for the future: setting a non-default server may exercise different
code paths inside QDnsLookup, so this is not a replacement for having
proper DNS servers in the CI.
Fixes: QTBUG-129335
Change-Id: I81dcd4834972efa84c9ffffdd8aaafb68f20560b
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
(cherry picked from commit 10fea78bdcad2086c980fa1c1bbcd5bb543e4366)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Instead of failing tst_QDnsLookup and blaming the class for problems,
let's first verify that the resolver can resolve an address. If it can't
and we're not in the CI, then just skip the test.
I chose "a-multi" because a) it required the least variability in the
command-line and b) it has more than one RR in the RR set so it may find
more problems than "a-single".
Output when I forced a domain that doesn't exist:
QWARN : tst_QDnsLookup::initTestCase() Default DNS server in this
system cannot correctly resolve "a-multix.test.qt-project.org"
QWARN : tst_QDnsLookup::initTestCase() Please check if you are
connected to the Internet.
QDEBUG : tst_QDnsLookup::initTestCase() Output was:
Server: 127.0.0.53
Address: 127.0.0.53#53
** server can't find a-multix.test.qt-project.org: NXDOMAIN
SKIP : tst_QDnsLookup::initTestCase() DNS server does not appear to
work
Task-number: QTBUG-129335
Change-Id: Id2dcc2ce7cfdd83c556ffffddb88a1f1b4339606
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
(cherry picked from commit 40986460e3f372cdb42ad80377455dc43b7cdb42)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
It must for QHostInfo, but DNS servers are not required to have that
label. It appears to be a good practice the majority of admins follow,
but it's not universal, so we cannot require it.
But if it does resolve, then RFC 2606 requires it resolve to 127.0.0.1.
Task-number: QTBUG-129335
Change-Id: Ib3b11de6616665658a20fffd754f2fbd78780b1c
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
(cherry picked from commit 252bd7c67ce7a0ed3c41059f551f87f0f77b5606)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Amends commit 46f407126e ("MetaObject:
store the QMetaType of the properties"), from 6.0 cycle, which made
QMetaProperty::{read,write}() use the actual enum type in the
QVariant. But it missed the case where the input QVariant contained a
string with the enum's values.
Note this is *not* a type-punning in all cases: if the type of the
property was marked as a Q_FLAG, moc generates code to access it as
int. That is fixed in the next commit.
Drive-by compare QMetaTypes instead of their IDs, which avoids
generating a call to register them.
Pick-to: 6.5
See-also: https://lists.qt-project.org/pipermail/development/2024-September/045636.html
Change-Id: I1cfce869090c96bb41b6fffdc20855cfa7cb2a18
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
(cherry picked from commit 1f9ab3767ed625a090af45f26dffd10dcd05eef5)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
QUniqueHandle allows us to write RAII types for non-trivial classes. We
can add some specialisations for 2 types of win32 handles, file
descriptors and FILE*
Change-Id: I4d6af274bcc7f84ae009d0cb3a2f3aec1b6bcaf9
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit 0563862e23eda4a7b8def8c8afacf732b9a992ef)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Both APFS and HFS+ can be both case-sensitive and case-insensitive
(the default), and the mounted file system may be any other file
system than these two as well, so hard-coding to case-sensitive
is not sufficient.
Task-number: QTBUG-28246
Task-number: QTBUG-31103
Change-Id: Ibdb902df3f169b016a519f67ad5a79e6afb6aae3
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit 3d08816f4c4245f08a53307775fe3c4ed31a7a32)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
When calling setParent for a top-level widget that used RHI it's
not enough to check if the widget's parent used RHI, as that's
always going to be false.
Missing this results in not sending textureChildren events for the
reparented widget.
Amends eb4cb71925
Fixes: QTBUG-129299
Pick-to: 6.8.0
Change-Id: I632d8d63ec56243cd6da2b196ad9651c28128f0b
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
(cherry picked from commit 0704eff5617a100634c58177c83ed0d90b6f5525)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
To enable adding and managing multiple QtQuickViews,
QtServiceEmbeddedDelegate now hosts a set of QtViews instead of a
single one.
To avoid crashing if the QML view has a TextField, do not allow
QtWindow to create a QtEditText if the service usecase is detected.
Fixes: QTBUG-129412
Task-number: QTBUG-127422
Task-number: QTBUG-128563
Change-Id: I70784657ed6cb2aa853160605f4663e517f0e6db
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
(cherry picked from commit 1656a2f58c759c25e6a89435a65c1d0fceba8a09)
This patch makes it possible to have multiple QtViews
in an Android app, provided they are in the same Context.
Task-number: QTBUG-127422
Task-number: QTBUG-124116
Change-Id: I3d5bef3f789f23c8495c3b7209bbd3e430d439ac
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
(cherry picked from commit 0af53d3e87464a0638e4fdb8b68287912281a2a6)
Returning an enum instead of a boolean lets us discern between
differences such as libraries have been loaded successfully, or
they have already been loaded successfully in a previous call.
Later, we could add more values to discern between the different
error cases, instead of relying on logging.
Task-number: QTBUG-127422
Task-number: QTBUG-124114
Change-Id: I66bd95e66772db8b6f940b30a7b121b35ff4390a
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
(cherry picked from commit 1afb82c41c54d6bbe3cd09cffc679fbfa86f75d3)
To avoid calling functions in QAndroidPlatformWindow during/after
destruction of the object, create a mutex and use lock_guard to
synchronize the destruction of the object and native function calls
originating from Android events.
Task-number: QTBUG-118231
Change-Id: I29818386456c6969ca507d74574b722bf8a19019
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
(cherry picked from commit 0f20feea2112c2391e274dc4e81aa38a738b7023)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Clean up any resources using the Android Surface when it
has been destroyed. Previously the resource clean up was done
only after Qt app state changed to Hidden or below and we initiate
the removal of the Surface. However, in the case of QtSurface
which is a SurfaceView, it will destroy its Surface before
we ever get to that part, leading to the resources holding
a reference to a destroyed Surface.
Task-number: QTBUG-118231
Change-Id: I282ddcc2813bf0a4e19cbb906376258dd2b4004f
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
(cherry picked from commit 9343d1ab6e1a5df3166d211809f2eb0e5a3cd878)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
QAndroidPlatformOpenGlWindow creates an EGLSurface to wrap
the native Android Surface. Once this EGLSurface is returned
to QPlatformEglContext, nothing is guarding it anymore,
and Android can freely destroy the underlying Surface.
This leads to failed EGL operations when leaving from the app
or returning to it, as that is when Android destroys/recreates
the Surface.
Use the mutex from QAndroidPlatformWindow to guard setting the
Surface, and during the makeCurrent() and swapBuffers() calls.
Locking until returning from these functions ensures Android
cannot destroy the Surface in the middle of them.
Task-number: QTBUG-118231
Change-Id: I614575c42f7f0c2c17022994d3bc542726ebf039
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
(cherry picked from commit e5513a9447771dc722ca27e553fd3e966ee7d44a)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
QtWindow is adding QtEditText to its view hierarchy in qtMainThread,
instead of the main thread. This causes crashes.
Fixes: QTBUG-129201
Change-Id: I10a638d281198a82edc7a81e23182b0c66e83a0b
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
(cherry picked from commit cc0629a4877ff7609094a29e4a18252c0de057b0)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
If a user accidentally passes 'CMAKE_OSX_ARCHITECTURES=x86_64;arm64'
to configure on a Linux x86_64 platform, the build would fail when
compiling qdrawhelper_avx2.cpp.o either due to an architecture
mismatch, or due to not recognizing the -Xarch flag on older gcc
compilers.
Only add xarch flags to SIMD compilation on Apple platforms.
Change-Id: I322316979626b04cb0378f4dbf3cc26ec96183ac
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
(cherry picked from commit 3f3d8604e6ed5b6854301f4a3c4799cfa256d8b0)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This reverts commit 9a11273b745a30cebb5cd648c89eb224e9704492.
Reason for revert: The fix tried to find a sensible order if
the same language is listed multiple times in QLocale::uiLanguages().
Anyhow, it breaks for lists where entirely different languages are listed. This needs more thought.
Fixes: QTBUG-129434
Pick-to: 6.7 6.5
Change-Id: I8c074cbf1ddc2ddf223ec09aef38dfc1ef7fc85f
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit f3fc7b210f79e5eb427b0ff49c45c5d6d390fb34)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
(cherry picked from commit a30c1bcd3c8b8eb4befeb254840224ca7bb52497)
Check the QPixelFormat instead of relying on an easily outdated list of
formats.
Change-Id: I076391ac22bc9d4e70e53232c529d09d7aab13b9
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
(cherry picked from commit fdc29cf057e7e2ec095405ff2b07bc082b0d4cdf)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Make shouldIncludeFs() class- instead of file-static by moving it into
QStorageInfoPrivate. Ditto isParentOf().
Put the functions under Q_OS_UNIX.
Fixes Clang -Wunused-function, and removes a non-q/Q-prefixed name
from the global namespace.
Amends 543ae6e6a4.
Manual conflict resolution for 6.8:
- tracked a user of shouldIncludeFs() that needs a QStorageInfoPrivate::
prefix added from qstorageinfo_linux.cpp to qstorageinfo_linux_p.h
Pick-to: 6.7
Task-number: QTBUG-77059
Task-number: QTBUG-126219
Change-Id: I4cc62ae044d74919d73d08f6ce3ad57f2e00b4c8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit 5cd154de63c517728d42ed322cb5f2965ef5f6ec)
Reviewed-by: Ahmad Samir <a.samirh78@gmail.com>
Reviewed-by: Lena Biliaieva <lena.biliaieva@qt.io>
Relax the dependency on Cups for PrintSupport module on non-APPLE
platforms. 30bb15e7bf42a07b49700b6e822513f125d9ed4d added the missing
dependency for the PrintSupportPrivate target, but made it required.
In general users not necessarly need the Cups found when linking
PrintSupport on non-APPLE platforms. So we may mark Cups optional.
We also need Cups as the required dependency when Qt is built
statically, since then QCupsPrinterSupportPlugin will require the
library to be found.
Amends 30bb15e7bf42a07b49700b6e822513f125d9ed4d
Pick-to: 6.7 6.5
Change-Id: Ia31d52f7beb9fab6ffa5123147a243f5be6345ef
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
(cherry picked from commit cce81f296eeae2d20f4f51e0ec4e0d3491e2f909)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
The cycle_p.h header assumes the configure system will set up various
HAVE_FOO defines, which we were not doing. We now selectively use
ARMV8_PMCCNTR_EL0 on Apple Silicon.
This is in line with the upstream change in
https://github.com/FFTW/fftw3/commit/7e92d5
We can't use DEFINES, as CMake doesn't allow function macros in
defines, so we manually use COMPILE_OPTIONS, as we know Clang
supports this.
For Intel the cycle_p.h header already does the right thing based
purely on the compiler-available defines.
Change-Id: Ib3da05c203955a6a377ba0eeb624f1cb430931e1
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit fd00d5569e738d2536c05b2fc3ef2517f415b272)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
The duplicateRequestsWithAborts test was missing this, causing failures
on macOS 14. Instead of adding it to each test function, we now set up
the temporary key chain in init(), and restore things in cleanup().
Task-number: QTBUG-119616
Change-Id: Ia9d80ae632774b8628417ad30d354a22b6a4916e
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
(cherry picked from commit 882e5d72fc2dcca3c35035564fbb9ce5abc4bc4c)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
QTest mouse emulation doesn't support drag & drop on wayland.
This is why all tests fail, where dock widgets are undocked by mouse.
Move skipping in the qCreateFloatingTabs macro, where possible.
Remove skipping where possible.
Fixes: QTBUG-129362
Change-Id: Ic71529f34b8bc39864c9eccadc2aff7b6d426ca8
Reviewed-by: Liang Qi <liang.qi@qt.io>
(cherry picked from commit 597f4bd4734e8a165929bc163ac910f44ba7a1e7)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
The helper function shows the main window and uses the
QApplicationPrivate::setActiveWindow() antipattern afterwards.
Use qWaitForWindowExposed() instead.
Task-number: QTBUG-129362
Change-Id: I915c5f8221e4e289950e917ad9c4fc2a7f5b9987
Reviewed-by: Liang Qi <liang.qi@qt.io>
(cherry picked from commit 899c89c8d71d90b30c21b688cfe6b62868ad1ee9)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This allows QQmlDelegateModel to know if a QAbstractItemModel subclass
is in the process of a reset, which it can't know if beginResetModel
was called in the model's constructor.
As an added bonus, it also allows us to warn the user if they call
endResetModel with a previous call to beginResetModel.
Task-number: QTBUG-125053
Task-number: QTBUG-127340
Pick-to: 6.7 6.5
Change-Id: I7d1fb983e9bf868c48472624ad945ae158115943
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
(cherry picked from commit 9d8663c18e88cb0b5a65f86cfd7726f3d31e04d6)
It went unnoticed (by me) the test was disabled via *.pro and later CMakeLists.txt
rather than BLACKLIST I was checking back then.
Fixes: QTBUG-129349
Change-Id: I509485bac9f32d544ef4bec120590a00d85ed608
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit e498a076ae035588ed6f29e91a20eb727d608342)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit fixes the broken layout. Wrapping the divs of
col-1 (content) and col-2(sidebar) classes with a container with
`display:flex` does the job.
Fixes: QTBUG-129178
Change-Id: I6867b178e5a1acf6a4fbd5302a857e5f3ca0a62f
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Reviewed-by: Kai Köhne <kai.koehne@qt.io>
(cherry picked from commit d39c9d37ade8d74e534952e47061168be8904fc7)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
(cherry picked from commit 148f1a5a898bec38cea0593427ed48eb75a629c0)
Types are automatically registered these days, so the remark about
explicitly registering them is out of date and can be removed.
Change-Id: I9c2b4dde8728a1d884ea37f00de919a037b6dca5
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
(cherry picked from commit fc28eb4688c36fa5f00867ebf9ae569e031ef446)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
QWindowPrivate::forwardToPopup() sends key events with
QCoreApplication::sendEvent(), which sets QEvent::m_spont to false.
That makes key and pointer events sent to popups appear synthetic,
while they are sponaneous if sent to other widgets.
The method has been newly implemented in the course of moving
popup handling from QApplication to QGuiApplication.
Make current behavior consistent to the behavior prior to
e4ef0f03e6.
Since events are always spontaneous, use
QCoreApplication::sendSpontaneousEvent() instead.
Add a test function to tst_QComboBox to Verify, that key events
- are sent directly to the popup
- not seen by the window
- appear as spontaneous.
This amends e4ef0f03e6.
Fixes: QTBUG-129258
Pick-to: 6.8.0
Change-Id: Iff61b98b290f6483948007b5f12b19393759d9db
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit 3fbae61ea245291cb4c34e9126562c307741a600)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
The YAMA LSM by default[1] prevents attaching the debugger to any
process that isn't a child. Since our backtracer comes from a child
process instead (i.e., tracing the parent), we must grant explicit
permission. This also makes QTEST_PAUSE_ON_CRASH=1 work.
[1] https://codebrowser.dev/linux/linux/security/yama/yama_lsm.c.html#ptrace_scope
Change-Id: Ic19d84a7a730c7f8fc0ffffd64e516447e4b1f35
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
(cherry picked from commit 731b1159f9da9d0a5f9871ceaef4b82b657b130c)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
We no longer support these iOS versions.
Change-Id: Ifcb2d0201ccc5017a088a05e491bcd0f4bfaa0e2
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
(cherry picked from commit 9fbfe72649c6637256766472ac8025dafe4fb778)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Ideally we want to catch if any of our selftests produce errors or
warnings from system frameworks that are out fault, but in this case
the warning does not seem to be something we can do anything about.
The "+[IMKClient subclass]: chose IMKClient_Legacy" warning is logged
via NSLog, so as a workaround we disable NSLog/CFLog output to stderr.
Change-Id: I17b6b83844c4160aa5980d954b70f2582ff94da5
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
(cherry picked from commit 493fa52e135f73c1496715bb45602d9a4da1ade4)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Intel CPUs have had this since 2013 (Ivy Bridge), but some older
Bulldozer AMD CPUs appear to be missing it. This creates a mismatch
between when the __haswell__ macro gets declared in qsimd_p.h and the
runtime check using the CpuArchHaswell value. That in turn creates a
condition where qInitDrawhelperFunctions() in qdrawhelper.cpp leaves the
memfill pointers set to null.
#elif defined(__SSE2__)
# ifndef __haswell__
qt_memfill32 = qt_memfill32_sse2;
qt_memfill64 = qt_memfill64_sse2;
# endif
...
#if defined(QT_COMPILER_SUPPORTS_AVX2)
if (qCpuHasFeature(ArchHaswell)) {
qt_memfill32 = qt_memfill32_avx2;
qt_memfill64 = qt_memfill64_avx2;
It does this so the qt_memfillXX_sse2 functions don't have to be defined
anywhere, so the QtGui build won't carry unnecessary dead code.
This is old code (from Qt 4.x) and several improvements I've made for
QtCore are not applied yet. My work for qSimdDispatcher[1] isn't
complete: it might have avoided this problem here, but it would also
have required major work for the draw helpers to work in the first
place.
[1] https://codereview.qt-project.org/c/qt/qtbase/+/537384
Pick-to: 6.7 6.5 6.2
Fixes: QTBUG-129193
Change-Id: Ia427a9e502b0fb46b2bdfffda8e2131b7091c9e9
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
(cherry picked from commit 54c24313fe1e4ed58b3260189cb623a7c852ab1d)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Amends c0014becca, which moved the code
that had depended on this.
Change-Id: I602661af164e6da118e1fffd0f9428c98b9ac2fb
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
(cherry picked from commit e15543a10a7d302aab05323a325630f1a9633192)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This is legacy behavior from Qt 3, before we had QFlags and before
QVariant could support user types. I cannot find any instance of a
getter returning an integer in current Qt or Qt Creator code. And note
this only compiles if the flags type with Q_FLAG - not Q_ENUM.
The content is wrapped as Qt 6.x only so it can be removed in Qt
7.0. The deprecation warning will come in a later commit, for 6.9.
Change-Id: Ie3ddd8025e3b4387866efffd8e8d46c3daa0dff2
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
(cherry picked from commit 939f7f56227e65c9797d17640a7b9c29166efc44)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
With the upcoming change to QFlags to support 64-bit, MSVC started to
complain that it can't convert from Qt::Alignment to QFlag and back to
Qt::Alignment. It is correct that this path has an explicit and
shouldn't be taken, but
a) it's worked for years
b) GCC and Clang insert an extra conversion to int (I guess)
In any case, header->iconAlignment is already a Qt::Alignment so we
don't need to go through QFlag here.
qcommonstyle.cpp(1666): error C2440: '<function-style-cast>': cannot convert from 'const Qt::Alignment' to 'QFlag'
qcommonstyle.cpp(1666): note: Constructor for class 'QFlag' is declared 'explicit'
Change-Id: If349995b779be9e3dab4fffd8701af8615ae407b
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit dc1f4b742edf469a61eb6067a5a0ca44aac6cd48)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Our workaround with a temporary keychain is not working anymore.
Startring from macOS 15 Security framework supports a new option:
kSecImportToMemoryOnly. Setting it to kCFBooleanTrue allows us to
import PCKS12 without accessing 'login' keychain and thus avoiding
blocking system-alerts requesting keychain access.
Fixes: QTBUG-128579
Change-Id: Ic86460b05dbee07194b146cefc45df6a478946b1
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
(cherry picked from commit 15817e7d29a5c496585ea0e45a8a8139f053f001)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Update QtEditText Layout parameters to match the item sending
the focus event while showing Android keyboard.
Task-number: QTBUG-125323
Change-Id: Ie7f32d66807e4c1d308d49483d1e72dc25eaa76a
Reviewed-by: Tinja Paavoseppä <tinja.paavoseppa@qt.io>
(cherry picked from commit 28df9a49776a88cb1a8e69348ae19a59b16a5b7e)
We need it for the most common operations in this function
(InvokeMetaMethod and all the property operations), so this avoids
duplication and ensures we always compile the static_cast.
Change-Id: I21b199bb5a1a1de632a3fffd45b339c2f3326100
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit 69ce741c186c9a1dd4ea9eecb7a51725c4e62342)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Commit e816f91541 ("Moc: avoid double
underscores in a generated identifier") added the CLASS..SCOPE..ENDCLASS
mangling to avoid creating double underscores, which are reserved to the
compiler and thus undefined behavior for us to use.
This commit changes that mangling to something similar to the IA-64 C++
ABI because a) that creates shorter identifier names that are often
easier to read if you have to open the moc result and b) will not
collide with a class name by the user that used SCOPE in the name, such
as:
namespace Outer { class Inner { Q_GADGET }; }
class OuterSCOPEInner : public QObject { Q_OBJECT } };
Before:
Q_CONSTINIT static const uint qt_meta_data_CLASSOuterSCOPEInnerENDCLASS[] = {
Q_CONSTINIT static const uint qt_meta_data_CLASSOuterSCOPEInnerENDCLASS[] = {
Now:
Q_CONSTINIT static const uint qt_meta_data_ZN5Outer5InnerE[] =
Q_CONSTINIT static const uint qt_meta_data_ZN15OuterSCOPEInnerE[] =
While I make no promises that this matches the mangling scheme, it can
actually be decoded by the c++filt(1) tool. The main difference (AFAICT)
is that we use the N..E production even for types in the global
namespace (e.g., "QObject" mangling should be "7QObject" but is
"N7QObjectE").
$ c++filt _ZN42QTBUG32933_relatedObjectsDontIncludeItself2NS3ObjE
QTBUG32933_relatedObjectsDontIncludeItself::NS::Obj
Pick-to: 6.7 6.5
Change-Id: I40b756c1ac0f6a986d79fffd14b2e245ac195afb
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
(cherry picked from commit b020bff6e9a2e45760bab61bdb84efc078c45f7f)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
It's an empty struct now, a.k.a. a "tag struct". It used to be the type
of the actual data prior to QtMocHelpers::stringData().
Change-Id: I490a0b19e05103c74305fffd20c71a51e94fc449
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
(cherry picked from commit d9b4309f0ec8719b2575bfd8b911d1b950a4d7ca)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>