32-bit Qt for macOS is now deprecated.
Change-Id: Idda4f4b3d48c58afae3932e7802bcf82cc75d3aa
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
OpenGL ES 3.1 introduces compute shaders. This patch enables them also
in QOpenGLShader/QOpenGLShaderProgram.
A GL/GLES example using QOpenGLShaderProgram for compute shaders is also
included.
Change-Id: I3951a302d7c2b096548f829b9b4578b5a525c453
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
These locations are where the official Android Studio IDE places its
copies of the SDK and NDK.
Change-Id: I2ea765c66a6ca4d11c573054375b797bd3da9d82
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Qt4->Qt5 regression:
QWindowsMouseHandler::keyStateToMouseButtons() cannot be used instead
of the old Qt4 function toQtMouseButtons() because Alt key and mouse
Xbutton have the same code on the Windows.
Task-number: QTBUG-55885
Change-Id: Ibad35cfe83145d03fd05f397c0afba9c86817a0c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
If the destination format is 32bit, we can convert directly in the
destination instead of in a buffer.
Change-Id: I2b4407da77b863deec7869c341e1a8d464b46600
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Collapse the tables that are mostly identical, to much shorter tables
and a simple functions to make it easier to read and maintain.
Change-Id: I44fdaebe9927b49a94385057756d9d87ad3c33f5
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Only return activity object when available and *not* when unavailable.
Task-number: QTBUG-55035
Task-number: QTBUG-50759
Change-Id: I60b1be528b2e4a3d630f4085b7642d74e18482bd
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Occurrences which should simply be removed entirely (due to always being
true or always being false as a result of the current OS support matrix)
have been left untouched for now.
Change-Id: I86d5a084cb84bc28fefc5191d40924de1439b3de
Reviewed-by: Liang Qi <liang.qi@qt.io>
QSysInfo::WinVersion, QSysInfo::WindowsVersion,
QSysInfo::windowsVersion(), QSysInfo::MacVersion,
QSysInfo::MacintoshVersion, and QSysInfo::macVersion() are now
deprecated.
QOperatingSystemVersion exists as a more flexible replacement.
Change-Id: Ib97d1bfb260f2595ba3c06ff8fd251c5de41cedc
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This removes the need to assign to the member variable
after constructing an instance.
Simplify code accordingly.
Change-Id: I9660f1ff2cb5a17b8eee697988bed03b76468112
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Change-Id: I682fabe8891e0325e6545b4499a59af4ad584c41
Reviewed-by: Mike Krus <mike.krus@kdab.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Which, in Mach speak, is an exception handler for the process. Also
check if the crash reporter is in a mode that will show a dialog for
any crashed process. If so, leave it to that crash reporter to do stack
traces.
This patch has the nice side-effect that a crashing test won't have both
a debugger and CrashReporter generate stack traces.
You can check the settings for CrashReporter on macOS with the command:
defaults read com.apple.CrashReporter DialogType
If it is set to 'basic' or 'developer' or 'crashreport', CrashReporter
will show the dialog. If set to 'server' it won't. Any unattended system
should have it set to 'server' (which will have QTest invoke lldb to
generate stack traces):
defaults write com.apple.CrashReporter DialogType server
Change-Id: I39153e44cff15c00341857f178b1dcfab154f8ee
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Incidentally, this means that the function will no longer include the
patch version number on Android, but this is more consistent with other
platforms like Apple and Windows anyways.
Change-Id: I9996317e73e491b3a139a511efe1384c57b73e0a
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This class provides a "type safe" way to compare and access operating
system version numbers.
[ChangeLog][Deprecation Notice] QSysInfo::windowsVersion() and
QSysInfo::macVersion() are deprecated and are replaced by the newly
introduced QOperatingSystemVersion.
Change-Id: I52b532de2e068ccf90faaa8342eee90c0a4145de
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This patch adds AVX2 versions of the fast blending functions that we
already have SSE2 versions of.
Change-Id: Ifd1a22f7891b6208cb74929ad26095d12c5a1efb
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The previous detection of device pixel ratio changes in paintDevice()
is not needed, as QBackingStore::beginPaint() already does this check
and calls resize().
Change-Id: I9ee8410fa3a5404c5ec19d2cba4543a9e3359fe9
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Only windows that are part of the application can be grabbed. This
excludes the system statusbar and other system overlays, as well
as windows of other applications. This is a limitation due to the
security model of iOS.
There exists APIs to grab a snapshot of the complete screen, but
these APIs return a view that can be used as a placeholder e.g.
during view transformations, and doesn't match our API that require
reading of pixels.
Task-number: QTBUG-49944
Change-Id: I8fd5b4c2777be1486f0ff22762d5e9b64c927e70
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Costs only ~300B in text size in QtCore, which is roughly compensated by
savings in other QtBase libraries, even without specifically porting
users to QL1S.
Of course, the raison d'être for this overload is avoiding the expensive
QLatin1String -> QString conversion which, for small lists, can take up
to 50% of the total runtime (assuming memory allocations dominate over
scanning and copying the list).
[ChangeLog][QtCore][QStringList] Added join(QLatin1String) overload.
Change-Id: I91d7e1d4e2c76d6dc79f2b750cf8e256dd4e0ab6
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The implementation was duplicated and spread out between QMacStyle,
QMacPaintEngine, and the Cocoa platform plugin.
Moving it into QtGui allows using it on other Apple platform.
Change-Id: Iadcbd71998204887e116271c575037789b6e2163
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Isolates the test from anything that might be going on on the globalInstance().
Enabled by the explicit thread-pool feature on QtConcurrent::run().
Add explicit timed wait (unit tests should contain as little indefinite waits
as possible).
Also avoids the use of QFutureSynchronizer, which makes my static QList
checker go nuts, with no way of fixing it until Qt 6.
Change-Id: I0829992642b2a49bb6a10ddd4b31eb3f88e3adeb
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
... and plaster API with nothrow (well, one function).
Change-Id: I36fd64c6fda5390954c82bba307c720d3b3215df
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The conditions aren't exclusive, but complementary.
This change removes one check for defined(Q_CC_INTEL) because it was
disabled before and requires testing before we confirm it to be correct.
Change-Id: I33dc971f005a4848bb8ffffd14748cde4dd23333
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Section 30.4.1.3 [thread.timedmutex.requirements] has 16 paragraphs and
2 subsections.
Change-Id: I9093948278414644a416fffd1473fec7fdd2716c
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
This macro expands into a static_assert and can be used to
trigger a compile error if a certain feature is not available
when trying to compile some code.
This is especially useful to protect against accidental inclusion
of headers that implement functionality related to a feature.
Change-Id: I456c55b989ce5f35f3af0e13c1886a85c23dfe29
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
This API was introduced by Android v23 and is used in connection with
the new permission request system. From Android v23 onwards, some
permissions such as Location permissions cannot only be granted via
Android's Manifest files. An additional runtime check/request system
was introduced which forces applications to prompt the user
the first time a privileged function is called. Such user prompt
responses
are returned to the current application via the
Activity.onRequestPermissionsResult(..) callback.
This change add Qt API to nicely check & request permissions. For now
this is private
API which can be used to fix permission problems in other Qt
compontents. Later Qt versions will introduce a public API to
QtAndroidExtras.
[ChangeLog][QtCore][Android] Introduced a mechanism to forward
permission related callbacks on Activity objects to interested parties.
Task-number: QTBUG-55035
Task-number: QTBUG-50759
Change-Id: I64ee748d741b39e35c4713ed9fdd15dd1d96dc56
Reviewed-by: Christian Stromme <christian.stromme@qt.io>
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
We're using QLocale::system() by default for conversions between
date/time and strings; locale-dependency should be left to QLocale's
methods, so we should switch to using the C locale for the date/time
classes' methods, to make the results locale-independent.
Task-number: QTBUG-55632
Change-Id: I6ea6e8d2289e537f4d26eccf69a4f314c501f116
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The returned string is now more similar to what the Apple (macOS, iOS,
tvOS, watchOS) version returns, and helps prepare for a later patch that
removes usages of QSysInfo::windowsVersion().
Change-Id: I5ba2937b27169ffc6624ccb4e608e6ff56a179bb
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
EcmaScript mandates that number-to-string functions pad the resulting
strings with zeroes, up to the requested precision. QLocale actually
supports this, under the disguise of the "Alternate" flag, used by
QString::asprintf().
We split this flag into the three options it actually represents and
make IncludeTrailingZeroesAfterDot available as a NumberOption. This
allows us to generate numbers in an EcmaScript compliant way.
In addition, a symmetrical option to reject trailing zeroes when
parsing strings to numbers is added.
[ChangeLog][QtCore][QLocale] Additional flags in QLocale::NumberOption
allow generating strings from doubles in accordance to EcmaScript's
Number.toPrecision(n).
Change-Id: If1090d5a0364a29811011a472afc8b75d0af0a8f
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Redoes the simple calculation of x coordinates in integer registers
rather than use the potentially expensive extract/move from NEON
register.
Change-Id: I914b463d6c20be2281710d626407196112d1615b
Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
android is linux, but the QPA plugin is not enabled by configure, so
skip the warning here.
Change-Id: Ib136dd142b775a00686cdaa0cec5414d035c9516
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
remove the redundant 'Style' suffix, and use CamelCased words (the list
uses space as a separator).
Change-Id: I169a741fdc293ac42ae6b97a5726477b53127506
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
... to the new qmake based configuration system.
This removes the old qfeatures.txt (distributed over configure.json
files) and qfeatures.h (distributed over qconfig-<module>.h files).
qfeatures.prf is gone without replacement, as attempts to use it would
lead to followup errors anyway.
Change-Id: I1598de19db937082283a905b9592d3849d2199d0
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Always include qtprintsupportglobal.h before checking the
ifdef, and add ifdef's where they where missing.
Change-Id: I535dce33b26955fb0196ea05d54be41fe93e9151
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
"description" suggests something slightly longer.
this may seem like a gratuitous change, but the upcoming replacement of
the old feature system clarifies makes it seem much less so.
Change-Id: Ibe702e01cb146b59127bf1f990b4acaef1c61d55
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Move the different parts of configure.json/.pri into the libraries where
they belong.
Gui is not yet fully modularized, and contains many things related to
the different QPA plugins.
Done-with: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Change-Id: I6659bb29354ed1f36b95b8c69e7fce58f642053f
Reviewed-by: Lars Knoll <lars.knoll@qt.io>