Commit Graph

63509 Commits

Author SHA1 Message Date
Tor Arne Vestbø
9965630aaf lldb: Look up Qt Creator version via Info.plist instead of mdls
For some reason mdls fails to resolve the kMDItemVersion for Qt
Creator in some cases, even if the Info.plist has the required
version keys, and the version shows up fine in Finder.

Work around it by manually reading the version from the Info.plist

Fixes: QTBUG-117204
Change-Id: I60d57fb728608e139a4540fabf1006fc2681d0a7
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-09-23 03:38:53 +02:00
Tor Arne Vestbø
fe3e0fc657 lldb: Improve reporting when loading summary providers
If loading the lldbbrige fails, we'll continue on to the next
Qt Creator version if we find one. It makes more sense to report
that we're about to load from a given version, so that any error
messages from lldbbridge are output with that context in place.

Change-Id: Icbab6f7d39333ce76d729fd0769cfdb44f05a2f0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-09-23 03:38:52 +02:00
Tor Arne Vestbø
e0eb2818fa Avoid extending dirty region in beginPaint
When the raster window is resized, we need to resize the backingstore,
and make sure we repaint the entire window. We defer the backingstore
resize to beginPaint, in case multiple resize events come in before
we have a chance to paint, but we can't defer the invalidation of the
paint device window, because QPaintDeviceWindowPrivate::paint() has
already subtracted the paint region from its dirty region at this
point. Invalidating yet again will result in the dirty region of
window not clearing fully until after the final resize, and when
that happens we will also repaint the window with the wrong dirty
region, based on the window's original size.

My moving the window invalidation to the resize event, while keeping
the deferred backingstore resize we avoid this problem.

Pick-to: 6.5 6.6
Change-Id: I44662778f5b1bcd259b20ca86124e6487561ef4f
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2023-09-22 23:47:41 +02:00
Tor Arne Vestbø
953e7eece8 QKeyMapper: Remove indirection via QKeyMapperPrivate for possibleKeys
Change-Id: I1988ac60689b3e6f4b29e38d1167d2b998702c09
Reviewed-by: Liang Qi <liang.qi@qt.io>
2023-09-22 23:47:39 +02:00
Tor Arne Vestbø
96e762e5a4 QKeyMapper: Merge default implementation of possibleKeys into call site
Task-number: QTBUG-116873
Change-Id: I9091f4a9d465fb928afcabce0536fcd2d03b7f82
Reviewed-by: Andrey Butirsky <butirsky@gmail.com>
Reviewed-by: Liang Qi <liang.qi@qt.io>
2023-09-22 23:47:39 +02:00
Ahmad Samir
f58df04196 QConcatenateTablesProxyModel: simplify code
If there is a reason to static_cast to `const QAIM*` then cast away the
const, I failed to see it. QObject::sender() returns a non-co.

Change-Id: Ibf8c8613c3de1584b426269c1ffba94db75d26d6
Reviewed-by: David Faure <david.faure@kdab.com>
2023-09-22 22:49:35 +03:00
Rym Bouabid
ba98644180 Revamp Subscription example: Cretae QString using a Literal operator
Create QString at compile time using the literal operator""s instead of
using pointer to characters. This way, no conversion or allocation will
occur at runtime.

Task-number: QTBUG-117425
Pick-to: 6.6 6.5
Change-Id: I2a19d4fe1150aad7908d0c2a7215099bc0814e8d
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
2023-09-22 21:02:45 +02:00
Rym Bouabid
9ed067e719 Revamp Subscription example: Fix includes
Add needed includes and remove uneeded includes.

Task-number: QTBUG-117425
Pick-to: 6.6 6.5
Change-Id: Iec4cc7a862aa164742e502f33447fa939dfb53ae
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
2023-09-22 21:02:45 +02:00
Rym Bouabid
ed72a5d9e1 Revamp Bindable Subscription ex: Cretae QString using a Literal operator
Create QString at compile time using the literal operator""s instead of
using pointer to characters. This way, no conversion or allocation will
occur at runtime.

Task-number: QTBUG-117422
Pick-to: 6.6 6.5
Change-Id: I92eed0a371bf6383ddb1e938646029f1c24242bf
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
2023-09-22 21:02:45 +02:00
Rym Bouabid
a69be76a30 Revamp Bindable Subscription ex: Fix includes
Reorder the includes following the coding conventions.

Remove unneeded includes.

Add needed includes to avoid Transitive includes.

Task-number: QTBUG-117422
Pick-to: 6.6 6.5
Change-Id: Iaf2b939bc160312de8aa4035da03b648cf76f17d
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
2023-09-22 21:02:45 +02:00
Ievgenii Meshcheriakov
24e504d9df QDBusConnectionPrivate: Fix race in sendWithReply()
The message processing may finish before watcherHelper is
setup. Use locking and an additional check for message
processing completion to avoid the race condition.

Move the code to new function inside QDBusPendingCallPrivate,
close to where the waiting without GUI is done.

Add assertions that check that watcherHelper is not overwritten.

Change-Id: I24e54598135edf293c41b3a80369b0a3b46f775c
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2023-09-22 21:02:45 +02:00
Leena Miettinen
406f676843 Doc: Edit docs for QtCore QT_I18N_ CMake variables added in Qt 6.7
- Fix punctuation and link errors.
- Make wording more consistent.

Change-Id: I5954a5c3129fdaf524918b2f1c60cc510374c505
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2023-09-22 21:02:45 +02:00
Volker Hilsheimer
c4a8c2b0d0 Silence compiler warning
Don't get a QModelIndex out of a temporary QPersistentModelIndex.

Pick-to: 6.6
Change-Id: Ida9e25f1a17130e19b75221e1189e6f2fccd3f27
Reviewed-by: Santhosh Kumar <santhosh.kumar.selvaraj@qt.io>
2023-09-22 20:40:36 +02:00
Alexandru Croitor
bf2587d9e5 CMake: Update the ios assets manual test
- provide an asset catalog .json file for both Xcode 13 and 14
  formats. Apps built against the Xcode 13 SDK are not validated
  anymore by the App store, but it's still useful to see how things
  were before.

- Xcode 13 required the following icon sizes for a universal iOS app:
   60x60@2x, 76x76@2x\~ipad, 167x167, 1024x1024

- Xcode 14 only needs the 1024x1024 one

- icons need to be embedded into the asset catalog starting with iOS
  11 according to Apple docs (not sure which Xcode version, but it's
  needed for both Xcode 13 and Xcode 14), and they don't have to
  manually be copied into the bundle anymore, Xcode takes care of
  that when processing the asset catalog

- add an 167x167 icon image for the iPad pro for Xcode 13

- add an 1024x1024 icon image that is required for successful app store
  submission and embed it into the asset catalogs

- for Xcode 13, we need to manually specify all the required icon
  sizes

- for Xcode 14 we can rely on Xcode to generate the smaller icons from
  the big one

- because the icons need to live in the asset catalog folder, remove
  unnecessary icons in the appicons folder.

- for the cmake project, make sure the asset catalog compiler generates
  the icons by setting the
  XCODE_ATTRIBUTE_ASSETCATALOG_COMPILER_APPICON_NAME attribute
  qmake does automatically already.
  it would be nice if we can do that automatically in a future Qt
  version

- remove unused icon references in Info.plist file with Xcode 13

- remove all icon references in Info.plist with Xcode 14, rely on Xcode
  to add that info via its generated partial Info.plist file that gets
  merged into the main one.

- don't include CMakeLists.txt as a text resource

Amends cf3535fdf2

Pick-to: 6.5 6.6
Task-number: QTBUG-104519
Task-number: QTBUG-110921
Task-number: QTBUG-116784
Change-Id: I0bc556e66647a66bc21402ea62db3374d0970e97
Reviewed-by: Amir Masoud Abdol <amir.abdol@qt.io>
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
2023-09-22 20:40:36 +02:00
Alexandru Croitor
370962315a CMake: Fix incorrect UILaunchStoryboardName value in Info.plist
The value needs to be 'CustomLaunchScreen', not
'CustomLaunchScreen.storyboard', otherwise app store validation will
fail with the following error:

 Asset validation failed
 Invalid bundle. Because your app supports Multitasking on iPad, you
 need to include the CustomLaunchScreen.storyboard launch storyboard
 file in you bundle. Use UILaunchScreen instead if the app’s
 MinimumOSVersion is 14 or higher and you prefer to configure the
 launch screen without storyboards.

This brings the value in line with what we have for the qmake
Info.plist file.

Amends cf3535fdf2

Pick-to: 6.5 6.6
Task-number: QTBUG-104519
Task-number: QTBUG-110921
Task-number: QTBUG-116784
Change-Id: I4e9cc2ed685634544955e967f35fdc426dac0f0c
Reviewed-by: Amir Masoud Abdol <amir.abdol@qt.io>
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
2023-09-22 20:40:36 +02:00
Alexandru Croitor
528e70b6d9 CMake: Add CFBundleIconName key to ios assets manual tests
It is required for publishing an app to the app store. Otherwise during
app store validation phase, you get an error:

 Asset validation failed
 Missing Info.plist value. A value for the Info.plist key
 'CFBundleIconName' is missing in the bundle 'foo'. Apps built with
 iOS 11 or later SDK must supply app icons in an asset catalog and must
 also provide a value for this Info.plist key.
 For more information see
 http://help.apple.com/xcode/mac/current/#/dev10510b1f7.

Note this is not needed when using Xcode 14.3+ and when one places the
icons into an asset catalog. When processing icons in the asset
catalog, Xcode generates a partial Info.plist file that will contain
the CFBundleIconName key and will merge into the final Info.plist
file.

Amends cf3535fdf2

Pick-to: 6.5 6.6
Task-number: QTBUG-104519
Task-number: QTBUG-110921
Task-number: QTBUG-116784
Change-Id: I53009097cf27b096c72ee9c4bad6aa4286272061
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
Reviewed-by: Amir Masoud Abdol <amir.abdol@qt.io>
2023-09-22 20:40:35 +02:00
Rym Bouabid
a0bd124a56 Revamp MIME Type Browser Ex: Revisit documentation
Remove "Example" from the title.
Add \examplecategory {Data Processing & I/O}.

Task-number: QTBUG-117146
Pick-to: 6.6 6.5
Change-Id: I6004f6708299886d6423325a551a9fd03a4a57df
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
2023-09-22 20:21:23 +02:00
Rym Bouabid
e6c8c16afb Revamp MIME Type Browser Ex: Replace QObject by Q_DECLARE_TR_FUNCTIONS
When declaring MimetypeModel class, use Q_DECLARE_TR_FUNCTIONS Macro
instead of Q_OBJECT as we only need to call tr() functions.

Task-number: QTBUG-117146
Pick-to: 6.6 6.5
Change-Id: Ic7afd4a806d57ba2a651ebe129f3a91f35764354
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
2023-09-22 20:21:23 +02:00
Rym Bouabid
00d8d566c6 Revamp MIME Type Browser Ex: Fix includes
Fix include order to respect the Coding Conventions.

Remove QT_{BEGIN,END}_NAMESPACE because these are private Qt macros that
should not be used in the examples.

Task-number: QTBUG-117146
Pick-to: 6.6 6.5
Change-Id: Iba7a4726180ec97d9654ed3b934baca8c1df0b5c
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
2023-09-22 20:21:22 +02:00
Rym Bouabid
81857ad5c3 Revamp MIME Type Browser Ex: Fix too long lines
Fix code lines that do not respect the 100 characters limit rule.

Task-number: QTBUG-117146
Pick-to: 6.6 6.5
Change-Id: I9833e9a25a09833b3e0384c95af8a422d5aa4582
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
2023-09-22 20:21:22 +02:00
Tor Arne Vestbø
a0792da126 xcb: Work around GCC ABI issue causing warning on ARM
In member function ‘virtual QDpi QXcbScreen::logicalBaseDpi() const’:
 qxcbscreen.h:139:42: note: parameter passing for argument of type
 ‘std::pair<double, double>’ when C++17 is enabled changed to match C++14 in GCC 10.1
     QDpi logicalBaseDpi() const override { return QDpi(96, 96); }

It's not possible to silence this warning/note using pragmas.

Pick-to: 6.6 6.5 6.2
Change-Id: I913a1753ce0c82ac17951faa58b0a88bf1daa4db
Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
Reviewed-by: Marc Mutz <marc.mutz@qt.io>
2023-09-22 20:08:05 +02:00
Morten Sørvig
0e23865c9e wasm: Improve screen cleanup
Fix the use case where the application recreates the
QApplication object while reusing the html container
element. This would cause an error:

  Uncaught DOMException: Failed to execute 'attachShadow' on
  'Element': Shadow root cannot be created on a host which
  already hosts a shadow tree

It looks like there is no way to remove a previously
attached shadow root, which means we can't return the
container element to its initial state if we attach
to the user-provided container element.

Fix this by introducing an intermediate element which
we can remove() in the QWasmScreen destructor.

Pick-to: 6.6 6.5
Change-Id: I929393a498b0440390a3e2c1774a3cac3a5a7e79
Reviewed-by: Piotr Wierciński <piotr.wiercinski@qt.io>
Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
2023-09-22 16:51:43 +00:00
Leena Miettinen
201c30986b Doc: Edit CMake Qt6 Core variable docs
Edit the docs for style and consistency.

Pick-to: 6.6.0 6.6 6.5
Change-Id: I24fb7f8b833ae7e5adaca31811bd171d892c5907
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2023-09-22 17:44:27 +02:00
Kai Köhne
868b721246 Remove unused snippets/rsslisting files
The snippets from the files were used in the QXmlDefaultHandler
documentation that got moved to qt5compat in Qt 6 (commit
79e0374143).

Change-Id: I11f19c8b2c5f693e203925bd2b19cff8d3380580
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
2023-09-22 15:44:27 +00:00
Alexey Edelev
bfe62b0224 Remove framework-related functionality from syncqt
The files generated by syncqt should land not only in module include
directory, but also in framework directory. Before syncqt made two
copies of the generated files one in staging directory and the second
one in module framework directory. This commit moves all logic related
to framework header files to cmake scripts. This is done for both
consistency and simlifying the logic. The whole module .syncqt_staging
directory is copying to the framework library in cmake.

[ChangeLog][Tools][syncqt] '-framework' and '-frameworkIncludeDir'
arguments were removed. The related logic is moved to cmake scripts.

Task-number: QTBUG-116483
Pick-to: 6.6 6.5
Change-Id: If79c5470d2ab51eb7fc083bce6fb01858bed76ba
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2023-09-22 17:44:27 +02:00
Marc Mutz
aa19704bbc Un-deprecate qSwap()
It seems to have fallen prey to the mass-deprecation of <QtAlgorithms>
in Qt 5.2. Since it didn't actually duplicate STL functionality, that
was uncalled-for: Unlike std::swap(), it's ADL-enabled, so the docs
were wrong to suggest replacing it with std::swap instead.

In fact, the tony-table that 5957f245c6
added to qalgorithms.qdoc didn't include qSwap(), yet, qSwap() was
marked as deprecated.

Un-deprecate and expand the discussion to more faithfully represent
its value, without going into the depths of teaching how to swap
correctly in C++ (link to boost.org and cppreference.com for that
instead).

Remove the example that used qSwap() on doubles, which is precisely
_not_ how you should use it.

Amends 5957f245c6c77c98d7e90d614c9fe2cdbfe7e8e6(!).

[ChangeLog][QtCore] Un-deprecated qSwap().

Pick-to: 6.6 6.5 6.2 5.15
Change-Id: I4981005ba71b0d1824f2a46897145255fa66a7ea
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2023-09-22 15:54:31 +02:00
Alexey Edelev
42d2944191 Add coverage and coverage-gcov features
Features enable code coverage collecting using the gcov tool. The
resulting reports can then be post-processed by lcov or similar tools.

[ChangeLog][CMake][Coverage] Added the coverage configuration argument.
The only supported coverage tool at the moment is gcov. The argument
requires Qt is built in Debug otherwise setting the argument leads to
the configuration error. Typical usage:
  <...>/configure -developer-build -coverage gcov

Task-number: QTBUG-86223
Change-Id: I39b2061f544997a7c4fe6f4d135c0ab447f15a17
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2023-09-22 15:54:30 +02:00
Kai Köhne
f2ec221bd6 Make examples/bindableproperties a proper project
Both executables (subscription, bindablesubscription) are documented
as one project. Make sure that e.g. Qt Creator can also load this
project.

Fixes: QTBUG-117109
Pick-to: 6.5 6.6 6.6.0
Change-Id: I3912f2f76379940b02f3a57a7a55440a30366755
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2023-09-22 11:24:16 +02:00
Kai Köhne
ec32748b1e Doc: Fix location of QT_REQUIRE_VERSION documentation
<QMessageBox> is not a (separately documented) header. QDoc
therefore puts the documentation on a separate proxy page:

https://doc.qt.io/qt-6/qmessagebox-proxy.html

Fix this by actually linking to the type.

This amends  95a3f85a2f, which moved the macro from
QtGlobal to QMessageBox.

Pick-to: 6.5 6.6
Change-Id: Ia2ed3d9fd786732c85d731634ff79afefe42333b
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
2023-09-22 09:24:16 +00:00
Volker Hilsheimer
cf0bd543d6 QJniObject: add callStaticMethod overload that takes class as type
Equivalent to get/setStaticField.

Add a test, and tighten up the surrounding test code a bit.

Change-Id: Ic0993c5d6223f4de271cb01baf727459b5167f94
Reviewed-by: Tinja Paavoseppä <tinja.paavoseppa@qt.io>
Reviewed-by: Petri Virkkunen <petri.virkkunen@qt.io>
Reviewed-by: Zoltan Gera <zoltan.gera@qt.io>
2023-09-22 07:18:21 +02:00
Volker Hilsheimer
e1a349983c JNI: move signature/className template functions into a template class
Template functions don't permit partial specialization, e.g. we cannot
specialize typeSignature() to return an array signature for any
std::vector or QList type. We need to do that for better array support,
so move those functions as static members into a template class, which
then can be specialized.

Since submodules are both calling and specializing typeSignature and
className as template functions, keep and use those until the porting is
complete.

Change-Id: I74ec957fc41f78046cd9d0f803d8cc9d1e56672b
Reviewed-by: Petri Virkkunen <petri.virkkunen@qt.io>
Reviewed-by: Zoltan Gera <zoltan.gera@qt.io>
Reviewed-by: Tinja Paavoseppä <tinja.paavoseppa@qt.io>
2023-09-22 07:18:16 +02:00
Volker Hilsheimer
0022b05a9a JNI: rename our compile-time String type to CTString
The type lives in the QtJniTypes namespace, which is where types end up
that are declared through the Q_DECLARE_JNI_CLASS/TYPE macros. Having a
String type in that namespace prevents us from declaring the Java String
class as a QtJniTypes type, which is silly.

Perhaps this type becomes obsolete at some point with std::string being
a constexpr type in C++23, but until then we need it. It has no ABI, so
renaming it us safe.

Until submodules are ported, leave a compatibility alias String type,
which also prevents us from declaring a String JNI class in tests until
the alias is removed in a later commit.

Change-Id: I489a40a9b9e94e6495cf54548238438e9220d5c1
Reviewed-by: Zoltan Gera <zoltan.gera@qt.io>
Reviewed-by: Tinja Paavoseppä <tinja.paavoseppa@qt.io>
Reviewed-by: Petri Virkkunen <petri.virkkunen@qt.io>
2023-09-22 07:18:10 +02:00
Volker Hilsheimer
dc126de22e QItemSelectionModel: don't warn when destroying the model
Amends 4f4a8e75ab, after which
QItemSelectionModel printed a warning when destroying the model.
We reset the selection model in response to the model getting destroyed,
and since the model is already set to be nullptr at this point the
select() function complains about changing the selection with no model
set being a no-op.

Fix this by not calling reset() when the model gets destroyed - the
stored selection and currentIndex are already reset at this point -
and instead only call reset() when a new model is set in initModel.

Fixes: QTBUG-117200
Pick-to: 6.6.0 6.6 6.5 6.2
Change-Id: I12fc6b3fb2f2ff2a34b46988d5f58151123f9976
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2023-09-22 01:42:45 +02:00
Aleix Pol
52a5a89ea4 QCommandLineParser: Warn invalid value calls
If the QCommandLineOption doesn't have a valueName, the parser won't
read the argument, therefore returning an empty value. If the developers
are calling ::value on the option, they clearly think it's expected to
get a value but won't ever be getting one, so we better warn them about
it.

Change-Id: I434b94c0b817b5d9d137c17f32b92af363f93eb8
Reviewed-by: David Faure <david.faure@kdab.com>
2023-09-21 22:05:06 +02:00
Marc Mutz
64c50224b9 Port qSwap()'s exception detection to C++17 std::is_nothrow_swappable
It's been available since C++17, and since we compile the trait
anyway, using it will probably speed up instantiation of qSwap()
(didn't test, just guesstimating).

Change-Id: If77ca71a8021a73edf4864bdd9e5fce517dcabb1
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
2023-09-21 22:05:06 +02:00
Marc Mutz
9d70118c66 qswap.h: include what you need
The qSwap() function needs std::swap, so include <utility> manually
instead of relying on transitive includes.

Pick-to: 6.6 6.5
Change-Id: If1331e1eabb55542eac7477522a8e906efb5379f
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
2023-09-21 22:05:05 +02:00
Marc Mutz
0bd3e28b17 qswap.h: use a more robust include guard
Just "QSWAP_H" is a bit meager to be unique. We don't really have a
monopoly on q-prefixed function and header names, there's the C std
function qsort(), e.g...

So use a somewhat more unique name as header guard.

Pick-to: 6.6 6.5
Change-Id: I554fa224afcb6858b752e8044ef3c03dfc69c084
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Ahmad Samir <a.samirh78@gmail.com>
2023-09-21 22:05:05 +02:00
Marc Mutz
88a109bede qswap.h: remove stale comment
It's now documented in qswap.qdoc.

Amends 9c706e2567.

Pick-to: 6.6 6.5
Change-Id: If6138df419dee165e9f1de4c0a0d68af1dcfaa42
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2023-09-21 22:05:05 +02:00
Joerg Bornemann
814de4c2ce CMake: Fix config condition evaluator
Use recursive descent to handle parentheses in config condition
expressions. This fixes cases like 'NOT (A AND B)'.

Fixes: QTBUG-117053
Change-Id: Iab1b6173abe00d763808bb972a9a5443ffa0938d
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Amir Masoud Abdol <amir.abdol@qt.io>
2023-09-21 21:46:46 +02:00
Joerg Bornemann
49ff83fcef CMake: Use while instead of foreach in qt_evaluate_config_expression
By using a while loop instead of a foreach(RANGE), we can simplify the
code and remove the skipNext variable.

Also, we need to access the last used iteration index in a future
commit. This is not possible with a foreach loop without saving the
index in another variable.

Change-Id: I39306a0105fb31a6a8f39e9d4c47ee3424599a2b
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Amir Masoud Abdol <amir.abdol@qt.io>
2023-09-21 21:46:46 +02:00
Joerg Bornemann
f5fc45bcb4 CMake: Remove superfluous code from qt_evaluate_config_expression
All of the continue() statements are not needed. There is no code after
the if-else chain.

Change-Id: I16188d14b4f05cb1e5f29bac4657149c4fce60a4
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Amir Masoud Abdol <amir.abdol@qt.io>
2023-09-21 21:46:46 +02:00
Kai Köhne
5bfac5358a Doc: Improve documentation for QMetaEnum::metaType()
Rephrase hard-to-read sentence.

Replace 'integral type;  with 'numeric type', as this seems
to be the terminology in the standard:

  The type-specifier-seq of an enum-base shall name an integral type

Finally, no need to use \sa for a method that is mentioned right before.

Pick-to: 6.6
Change-Id: I543041e78cc09ccd58182db454880941592c74ae
Reviewed-by: Andreas Eliasson <andreas.eliasson@qt.io>
2023-09-21 21:29:21 +02:00
Kai Köhne
802db7b523 Move rsslisting documentation to common dir
Move the rsslisting example documentation to examples/network/doc,
as it is done for all the other examples.

Fixes: QTBUG-117215
Pick-to: 6.5 6.6
Change-Id: If83202825afe8c69cb7fda0f84ca4832cf3d60e7
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
2023-09-21 19:29:20 +00:00
Nicholas Bennett
e7847a3258 Docs: Update Links to Android Notifier Example
Added to the list of important links on the Android Platform home page.

Task-number: QTBUG-116780
Pick-to: 6.2 6.5 6.6 6.6.0
Change-Id: Id65a73d56bff0b288ebb1da098f6dbd8cbbe606e
Reviewed-by: Rami Potinkara <rami.potinkara@qt.io>
Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
2023-09-21 17:28:43 +00:00
Alexandru Croitor
db17465d37 Fix reported QtCore copyright year
Pick-to: 6.2 6.5 6.6
Fixes: QTBUG-101162
Change-Id: I09df1e19d353ab93fb0042b2fa9a68c89d8a5399
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2023-09-21 19:28:43 +02:00
Tatiana Borisova
b856790d67 Add Q_ENUM macros for registering QSsl/QSslSocket in Meta-system
- Macros provide possibility to use enums in QML via QtNetwork QML module

Task-number: QTBUG-115056
Change-Id: I1ed96a7eb4b12681d16137528307fec6db5b016c
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2023-09-21 19:28:43 +02:00
Morten Sørvig
8bfdfd613e wasm: include qunixnativeinterface.cpp in build
Fix shared libraries build error:
  undefined symbol: _ZN16QNativeInterface7Private14QWaylandWindowD0Ev

We are declaring QWaylandWindow for all Q_OS_UNIX in
qplatformwindow_p.h, and must include the definition
as well.

Change-Id: I630538af475524659e9a476171994e600f2ec668
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2023-09-21 19:28:42 +02:00
Volker Hilsheimer
6c90aa029b QDockWidget: ignore close event if DockWidgetClosable is not set
[ChangeLog][QtWidgets][QDockWidget] A floating dockwidget that doesn't
have the DockWidgetClosable feature flag set can no longer be closed by
a call to QWidget::close or a corresponding keyboard shortcut (such as
Alt+F4).

Fixes: QTBUG-116752
Pick-to: 6.6 6.5
Change-Id: I7859a2eed11f0e4ee013f7f56611e282e9bcae9a
Reviewed-by: Santhosh Kumar <santhosh.kumar.selvaraj@qt.io>
Reviewed-by: Doris Verria <doris.verria@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2023-09-21 18:36:06 +02:00
Simo Fält
f07efb4819 CI: Enable changing chroot in platform config for Debian packaging
Allows us to change the target distro through platform configuration
yaml file.

Pick-to: 6.6
Task-number: QTBUG-117120
Change-Id: Ie6e99e4b25198e27491e6191f57d77dbbe3c4eed
Reviewed-by: Toni Saario <toni.saario@qt.io>
(cherry picked from commit 798175930e517e28230e3db3213510a22a041620)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
2023-09-21 16:16:46 +00:00
Joerg Bornemann
ff6eca0087 CMake: Add I18N_NATIVE_LANGUAGE keyword to qt_standard_project_setup
[ChangeLog][CMake] Added variable QT_I18N_NATIVE_LANGUAGE to specify the
native language that is used in the source code for translatable
strings.

[ChangeLog][CMake] Added keyword I18N_NATIVE_LANGUAGE to
qt_standard_project_setup to conveniently set QT_I18N_NATIVE_LANGUAGE.

Task-number: QTBUG-115845
Change-Id: I079256507685afe5eccda78beffff819292494bf
Reviewed-by: Amir Masoud Abdol <amir.abdol@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2023-09-21 17:00:22 +02:00