summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
...
* qtmetamacros.h: remove redundant Q_PRIVATE_QPROPERTYAhmad Samir11 days1-4/+0
| | | | | | | | | It was removed in commit e6988d4d0bef2c3f474576250cb305a2f00a688b. Pick-to: 6.10 6.8 6.5 Change-Id: Ia376c11cb8ace52472260cbde6424b9d1c082c97 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* qtmetamacros.h: don't use Q_ENUMS/Q_FLAGS in {Q_ENUM,Q_FLAG}{,_NS}Ahmad Samir11 days1-4/+4
| | | | | | | | | | | | Q_ENUMS and Q_FLAGS have been deprecated since at least Qt 6.0. Since the behavior doesn't change at all, pick it to stable branches to reduce git merge conflicts for backports. Pick-to: 6.10 6.8 6.5 Task-number: QTBUG-99060 Change-Id: Ib4153897b3e178d810627ab2a54f72b202a6b06b Reviewed-by: Marc Mutz <marc.mutz@qt.io>
* QRandomGenerator: remove direct use of HW instructionsThiago Macieira12 days2-6/+2
| | | | | | | | | | | | | | | | | | | | | The HWRNG instructions are not necessarily faster than what we can get from the OS. Moreover, the OS is able to collect entropy from sources other than the CPU itself. More importantly, this removes the need for Qt to deal with broken HWRNG, passing the buck to the OS (which may disable the CPUID bit, causing the application to fail to load). [ChangeLog][QtCore][QRandomGenerator] This class no longer directly uses a hardware random number generator on x86 systems, even if one is available. Instead, it will always use a generator provided by the OS (so performance will be OS-specific), though there should be no meaningful difference in the quality of the samples generated. Task-number: QTBUG-69423 Task-number: QTBUG-129193 Pick-to: 6.10 6.8 6.5 Change-Id: I5121c5a34d684983fa1dfffdbabd22de51966650 Reviewed-by: Jason A. Donenfeld <Jason@zx2c4.com> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* QuasiVirtual: remove unnecessary limitation for static assert checkArtem Dyomin12 days1-6/+6
| | | | | | | Instead of mask, constexpr std::array<bool> can be used. Change-Id: I912b00e2ac82d67536fd6ce516d6c4a9d4d1b6c1 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Move QQuasiVirtual to a separate headerArtem Dyomin12 days3-213/+243
| | | | | | | No functional changes. Change-Id: Iacbae1e04d9a9edd35acce17fd7ecf268fbe9340 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* QWindows11Style: Don't highlight disabled tabs on hoverWladimir Leuschner12 days1-1/+2
| | | | | | | | | Disabled tabs in a disabled QTabBar and QTabWidget should not be highlighted on hover. Pick-to: 6.10 Change-Id: Ie073479c914739d93dd09bb48d8787cfc031046b Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
* QWindows11Style: Don't change disabled QSlider handle inner radiusWladimir Leuschner12 days1-4/+7
| | | | | | | | A deactivated QSlider does not change the inner circle radius on hover Pick-to: 6.10 Change-Id: Ic254402b854c04a741037f9d32bad1dfcdc826ef Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
* QWindows11Style: Don't highlight disabled QSpinBoxesWladimir Leuschner12 days1-2/+3
| | | | | | | | Do not highlight disabled QSpinBoxes on hover. Pick-to: 6.10 Change-Id: I35fed09cccc85277e740ebd62deb7412713b300e Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
* qmenu: Adjust geometry passed to waylandDavid Edmundson12 days1-3/+5
| | | | | | | | | | | | The current code uses the qwidget->geometry() which is the position relative to it's parent widget. The QPA code needs the position relative to the toplevel window. Amends 4eed22e67ed98ec2565be84a4838955af0faf8b0 Fixes: QTBUG-141553 Change-Id: I5139d3b1afec00743bd8c8bb9af48001df2da97e Reviewed-by: Vlad Zahorodnii <vlad.zahorodnii@kde.org>
* a11y: Simplify implementation of QAccessibleTableIngo Klöcker12 days2-77/+8
| | | | | | | | | | | Since QAccessibleTable does now derive from QAccessibleWidgetV2 we can remove duplicate implementations of isValid(), role(), state(), and rect(). And adding the role argument to the constructor allows us to remove the guessing of the role. The factory already instantiates the correct (sub)class (of) QAccessibleTable. Change-Id: I6e0bb0ec4e8e706efa20df9458cd88abd991212a Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
* QRangeModel: implement autoConnectPolicyVolker Hilsheimer12 days3-15/+534
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A model that operates on a range holding items of the same QObject subclass presents the values of the properties of those QObject instances as its data. The property names will be used as the role names. It is then very convenient if changes to the properties in those QObject instances makes the model emit dataChanged() for the respective index and role. This requires that we identify the changed-signals for each property that corresponds to a role name, and connect to each of those signals for each object instance. This is an expensive operation, in particular for trees where we have to recursively traverse the entire sturcture. But a range holding QObjects is already quite expensive and therefore only reasonable for small models with dozens rather than thousands of items. At that scale, the overhead is acceptable, and we can store the respective meta data in a baseclass of our storage type, specialized for when the range's item type is the same QObject subclass for all columns. We know this already, as the default implementation of roleNames() uses that as well. Each connection goes to a functor object that stores the index and the role, which is the information we need to emit dataChanged. By storing the index as a QPersistentModelIndex, objects changing position in the model will automatically update the functor object. The public API for this is a policy property, with two values (plus the "None" default value): a Full auto connect iterates the entire model and connects all relevant properties. This is expensive compared to only connecting some objects and properties, but gives full coverage, and has no overhead other than the connection itself. The alternative is OnRead, which connects lazily when data is read for the first time. This is cheaper if it's unlikely that all objects and/or all properties are displayed, but adds book-keeping overhead so that we know when an object and role are already connected. If everything gets connected lazily, then this is substantially more expensive than doing a full auto-connect in the first place. When new rows or columns got inserted, and if autoConnectionPolicy is set to Full, then we need to connect the new objects after QAIM emitted rows/columnsInserted(). This gives clients a chance to populate the new cells with objects. When rows or columns are removed and the policy is set to OnRead, then we have to remove those connections from our book- keeping set. When objects are removed from the model (which means rows or columns are removed), then we need to break the connection to the respective objects. As the QObjects will likely be destroyed anyway, which will then break the connections, we disconnect lazily: we disconnect if our functor gets called for an object that has been removed. In that case, the stored QPMI will have become invalid. To break the connection, we need to store the QMetaObject::Connection in the functor object. However, we only get that connection handle as a result of making the connection, at which point our functor object has already been moved into Qt's QCallableObject data structure. In order to store the connection handle, we implement the move constructor of the functor to store the address of the move-constructed functor object in the moved-from functor object. This makes a moved-from functor act as a reference to the moved-to functor and we can use that to store the connection handle in the functor instance that is stored in the QCallableObject. Since a functor instance holds either the property data, or the address of the moved-to instance, we can use a std::variant to avoid overhead. Using a plain union would be even cheaper, but at this point, benefit from the guard-rails we get from std::variant. The context object for all connections is then a dedicated QObject, which we can simply delete to break all connections. [ChangeLog][Core][QRangeModel] A range model operating on a range that holds identical QObject sublasses for all items can now automatically connect the changed signals of all properties mapped to item roles to the model's corresponding dataChanged signal. This allows user code to change properties of the item-object directly, and model clients (like item views) will get updated. Change-Id: I742b57f0c90f705d8b7eb949ff0d026b8b4a52f3 Reviewed-by: Artem Dyomin <artem.dyomin@qt.io>
* a11y Android: Replace magic numbers of RangeType with java constantsJulian Greilich12 days3-5/+36
| | | | | | | | | | This also fixes that RANGE_TYPE_INTERMINATE is not available before apilevel 36. Task-number: QTBUG-139712 Pick-to: 6.10 6.8 Change-Id: Icb53204e0a7a369a161461b9e925436eb4e7c27b Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
* a11y Android: Use correct EventType TYPE_WINDOW_CONTENT_CHANGEDJulian Greilich13 days1-4/+7
| | | | | | | | | | | | | | | | | * The correct way to announce changes of accessible name, description and value is to use the EventType TYPE_WINDOW_CONTENT_CHANGED with the correct CONTENT_CHANGE_TYPE set. * We don't need to pass the (new) value anymore to the notifyValueChanged and notifyNameOrDescriptionChanged method anymore. * Now TalkBack plays a sound to represent changes of the value of e.g. the progressbar instead of announcing the value as text. Task-number: QTBUG-139712 Pick-to: 6.8 6.10 Change-Id: Ic9cd4f4cf212ba3cd3d392dacce1955d7cb2bf54 Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
* painting: fix build with -no-feature-raster-64bitNick Shaforostov13 days1-0/+4
| | | | | | | | | When compiling with clang, unused function results in a warning which is treated as an error Pick-to: 6.10 Change-Id: Ib212d7140907f7de623560bf1f09f205605d0f4c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* QDebug output: give timestamps of QEvents if verbosity increasedShawn Rutledge13 days1-1/+4
| | | | | | | | | | | | | | Event-handling behavior in Qt Quick nowadays relies more on the original event timestamp rather than time measured by other means in Qt. Seeing the actual timestamp is often necessary to troubleshoot autotests. Debug output for QEventPoints already has them, but it can be useful to see the event timestamps too. QDebug::setVerbosity(QDebug::DefaultVerbosity + 1) or greater is necessary to enable this, to reduce clutter somewhat. Change-Id: I26b627fbf6ec74101afa9807564eee6b78f254fb Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* iOS: Import documents when opening files via UIDocumentPickerControllerTor Arne Vestbø13 days1-1/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | As part of implementing support for native folder dialogs in dbe433f6d0259119fa31103b3428d50cc9fec286 we removed the import mode logic, switching away from UIDocumentPickerModeImport for files to effectively always preferring UIDocumentPickerModeOpen. This regressed file opening, as unless the application explicitly manages access to security scoped resources (files outside of its sandbox) the files selected in the file dialog will be inaccessible. We now pass asCopy:YES when we know we're opening files, which restores the previous behavior. For opening directories outside of our sandbox we can't pass the same flag, as folders can't be imported. As a result, the app can't see any content in the security scoped folders. This will be improve in a follow up that adds support for managing security scoped resources. Pick-to: 6.10 6.10.1 6.8 6.5 Fixes: QTBUG-117832 Change-Id: Ifdc3866c065e777357a2d400f980c27efb8eb9af Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* QStyleSheetStyle: don't call base implementation for PE_WidgetChristian Ehrlicher13 days1-1/+11
| | | | | | | | | | | | | Don't call the base implementation for PE_Widget for an QAbstractScrollArea when we have rules for it to avoid overriding of the style paintings by the base class. This was not visible until the windows11 style reimplemented the drawing for PE_Widget with 072bf40fe9597bdd910bb0c1e6a754c1a468b844. Pick-to: 6.10 6.8 Fixes: QTBUG-141819 Change-Id: I6e90dc6cb3b1a7151815d57d790c67317a97d589 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* QVariant: remove pointless castMarc Mutz13 days1-1/+1
| | | | | | | | | | | | | | | | Placement new wants to be called with a void* (cf. VOIDIFY() in std::construct_at()'s definition), so stop there, don't continue to cast to char*. This was already done for the primary overload of the in-place constructor, but forgotten in the initializer_list one. Amends c81e8f8ff24d30cc4c137d6f071954958e984ce9. Pick-to: 6.10 6.8 Change-Id: I5fe43d0062f2ad5e88603d5d231c2053f1164fed Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* [docs] Q_CONSTINIT: mention it attaches to definitionMarc Mutz13 days1-0/+12
| | | | | | | | | | | | | | | | | | | | The macro (like the attributes and the C++20 keyword that back it) belongs on the definition, not on the declaration, of the variable, because it's a static assertion on properties of its initialization. Some compilers apparently accept it on a non-defining declaration (or we only checked in C++17 builds with old compilers), but we have several variables in QtCore that are marked as described in this documentation addendum, and they've not caused problems in the CI all these years, so document as practiced, and ignore other combinations that theoretically may work, too (on some compilers, at least). Amends 80b6bcc385863a38d499685af9b8e857e46cbdba. Pick-to: 6.10 6.8 6.5 Change-Id: I825127ff9ade483584f399fda78b7c7082f68ed8 Reviewed-by: Ivan Solovev <ivan.solovev@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* macOS: Handle non-square system tray notification iconsTor Arne Vestbø13 days1-1/+11
| | | | | | | | | If the provided icon is non-square the system will end up clipping it, so let’s pre-generate a square icon if needed. Pick-to: 6.10 Change-Id: I71a21d2c50f1269227257c354b47a812b6566746 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* macOS: Handle non-square application icons by padding the iconTor Arne Vestbø13 days3-3/+37
| | | | | | | | | | The system scales NSApp.applicationIconImage to fit into the tile, but does so without respecting aspect ratio. To avoid stretched icons we pad the icon to make it square, if it's not already so. Pick-to: 6.10 Change-Id: Ib7fbc335586763817b92b8a2f0d73e828e6f85ea Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* macOS: Use underlying NSImage for symbol images when used in system trayTor Arne Vestbø13 days1-0/+13
| | | | | | | | | | | | | | | | | There's no need to flatten the image to a QImage in this case, and doing so loses the isTemplate state of the Image. By passing the NSImage on, we let AppKit decide how to configure and size the image for the menu bar, matching the look of SwiftUI's MenuBarExtra. Note that the look of system status bar UI such as the WiFi icon or battery icon is slightly larger than what the same icon will look like in a MenuBarExtra, but as long as SwiftUI behaves that way we try to match that instead of trying to compensate and align with the few "oversized" system UI icons. Pick-to: 6.10 6.8 Change-Id: Ia82e0bc471426345ff1b695b10c3fd463e357eb7 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* Add private QIconEngine hook to get underlying platform iconTor Arne Vestbø13 days7-5/+50
| | | | | | | | | | | | | | | | | | | | | | | | | This allows us to pass the underlying NSImage from the Apple icon engine to the NSMenuItem.image, without rasterizing it ourselves in the process. The latter is both inefficient, and does not result in correctly sized or aligned menu icons, as we don't have enough information at the point when we rasterize the icon in QAppleIconEngine::paint to determine the correct NSImageSymbolConfiguration for a menu icon (NSFontWeightSemibold, NSImageSymbolScaleSmall, and [NSFont menuFontOfSize:0].pointSize). By passing on the underlying NSImage we fix the broken icon sizes in native menus, but we still have wrongly sized icons in non-native menus (context menus in Qt Widgets, and non-native menus in Qt Quick). This comes down to the pixel metric for icon sizes (PM_SmallIconSize) being built for square icons, which does not work for the dynamic nature of the SF Symbols icons. In addition, PM_SmallIconSize is used for more than just menu icons, so we can't just update its value to make the non-native menus look slightly better. Fixes: QTBUG-140361 Pick-to: 6.10 6.8 Change-Id: I1e2cb4029688c824ec29546836a0820cb635722c Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* macOS: Use Apple icon engine directly for theme iconsTor Arne Vestbø13 days3-2/+10
| | | | | | | | | Instead of going via QIcon::fromTheme(), which may result in icons from a user-set theme instead of the SF Symbols theme. Pick-to: 6.10 Change-Id: Ib2325f6d64720239b98cb9eedf141514bae50a36 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* Add force vsync feature to VxWorksKarim Pinter13 days1-0/+11
| | | | | | | | | | Setting the QT_QPA_EGLFS_FORCEVSYNC environment variable forces vsync on VxWorks with eglfs, like on embedded Linux. Task-number: QTBUG-141663 Pick-to: 6.8 6.10 Change-Id: Ida68c8a027676ec41517be31a167d906ac43dc84 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* rhi: vulkan: Silence validation about VK_EXT_swapchain_colorspaceLaszlo Agocs13 days1-1/+3
| | | | | | | | | | | ...specifically with Wayland, and presumably some compositors. It tends to report VK_COLOR_SPACE_PASS_THROUGH_EXT. Validation is pedantic and warns about having to enable the instance extension. Pick-to: 6.10 Change-Id: Ie027e230f002af87fe0031357c3384a7c938d733 Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* Doc: Fix or remove self-referencing "see also" linksDavid Boddie14 days2-3/+3
| | | | | | | | | | Use a precise signature for a QMultiMap::count() overload. Remove links to QRandomGenerator64 functions as defines in the header file hide them from QDoc. Task-number: QTBUG-137048 Change-Id: I75994ae96d385d08730e3afc849fe81ea9e88dee Reviewed-by: Topi Reinio <topi.reinio@qt.io>
* Windows11Style: use QStyleAnimation for intermediate QProgressBarChristian Ehrlicher14 days1-1/+14
| | | | | | | | | | Don't directly call QWidget::update() inside the paint event and use QStyleAnimation instead which is the way to animate elements in styles. Pick-to: 6.10 Change-Id: I3dccff63ff8bdeb5ff4e7775919d908815ad083e Reviewed-by: Wladimir Leuschner <wladimir.leuschner@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Windows11Style: don't highlight disabled QLineEditsChristian Ehrlicher14 days1-2/+3
| | | | | | | | | | A disabled QLineEdit has neither a lineedit frame nor gets highlighted on hover Pick-to: 6.10 Change-Id: I2c6bc7b3cc42bb368620b4ffc19b4843cf219165 Reviewed-by: Wladimir Leuschner <wladimir.leuschner@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* wasm: a11y - Implement support for role Grouping aka 2/2 QGroupBoxEven Oscar Andersen2025-11-101-16/+38
| | | | | | | | QGroupBox uses a heading item, that should be visited. Task-number: QTBUG-140108 Change-Id: Ib07e1348a715c7b1cb5b3e71eb93110e3ccfde11 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: a11y - Support checkbox with children aka 1/2 QGroupBoxEven Oscar Andersen2025-11-093-1/+46
| | | | | | | | | | | | | The structure we create is: <Group> <label> <checkbox> .. <rest of the children> Task-number: QTBUG-140108 Change-Id: I3a6604f17443010748e9631934c03317a37bb4b4 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* Strict mode: add a note about updating the docs when adding to the listAhmad Samir2025-11-091-1/+4
| | | | | Change-Id: I451b540940bce98ae09c2855cd2b86ff9ba9bb2f Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* wayland: Fix regression with custom popup completersIgor Khanin2025-11-081-3/+7
| | | | | | | | | | | | | | | | | Commit 4eed22e67ed98ec2565be84a4838955af0faf8b0 has broken the handling of popup-based QCompleter that use custom positioning, e.g. those attached to multi-line QTextEdit widgets - as in the "customcompleter" example. Following that change, popups now appear above or below the parent widget, which is usually far away from the cursor position or whatever other "hot" rectangle the application needs. Treating the completer popup the same as a combo dropdown is just not correct. There is probably something better to do to allow the compositor to place such popups correctly, but for now the best course of action is to not opt-in to the new Wayland mechanism to avoid breakage. Change-Id: I237d5f49b185c6a8593ef2dd72c9bcb6c6ff4785 Reviewed-by: David Edmundson <davidedmundson@kde.org>
* Styles: remove checks for classes no longer availableChristian Ehrlicher2025-11-082-5/+1
| | | | | | | | | | | | | | The classes - QDockSeparator - QDockWidgetSeparator - QPlastiqueStyle - QCleanlooksStyle are not available in Qt6 so no need to check for them. Pick-to: 6.10 6.8 Change-Id: I5dc41526a3bdd8bb1d9d041a903307f6af9bf84d Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* wayland: Add color-management-v1 supportBłażej Szczygieł2025-11-089-321/+525
| | | | | | | | | | Replace xx-color-management-v4 with color-management-v1. [ChangeLog][Third-Party Code] New protocol synced from wayland-protocols Pick-to: 6.10 Change-Id: Ib8b6c4f491ff664a41e46ce25833cd7d956f19fd Reviewed-by: David Edmundson <davidedmundson@kde.org>
* wayland: Fix crash in QWaylandShmBackingStore::scroll()Błażej Szczygieł2025-11-081-1/+3
| | | | | | | | | | | | | Fixes a crash when monitor is unplugged while scrolling. recreateBackBufferIfNeeded() calls getBuffer() which may set mFrontBuffer to nullptr. Amends: 6f25f703fd37a900c139e14a33a4639502bfeae7 Task-number: QTBUG-139231 Change-Id: Ia5bedce2a3f6580c722f73446de81a26d40ea2f4 Reviewed-by: David Edmundson <davidedmundson@kde.org>
* Remove redundant self-reference in QDateTime::TransitionResolution docEdward Welbourne2025-11-071-1/+1
| | | | | | | | | Its \sa to itself is superfluous. Amends commit a49ccc08c307b7c7e1acc34752b81dd38ea43bfa (6.7). Pick-to: 6.10 6.10.1 6.8 Change-Id: If7ddd8b654c2f6076a4941aa25a020c7538537a6 Reviewed-by: David Boddie <david.boddie@qt.io>
* QCoreApplication: use unique_ptr in PermissionReceiverMarc Mutz2025-11-071-1/+1
| | | | | | | | | | | | | ... not shared. Amends 0bd1fc006097e481d8b92ee1c5246ffa1ae9379f, which removed the need for SlotObjSharedPtr, but didn't adjust the data member. Pick-to: 6.10 6.8 Change-Id: If5991d20b091271f9e38e2f621eb62020cee9871 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QFontMetrics: DRY engine lookup for single charactersMarc Mutz2025-11-073-37/+27
| | | | | | | | | | | | | | Extract Method QFontPrivate::engineForCharacter() and use it in inFont() and the single-char overloads of left/rightBearing(), boundingBox() and horizontalAdvance(). As a drive-by, receive QChar::script()'s result in an auto variable, to avoid converting to and from int. Pick-to: 6.10 6.8 6.5 Change-Id: Id2cf1a1781c4b3fb9657902fb065c6ec7f4d70c3 Reviewed-by: Ahmad Samir <a.samirh78@gmail.com> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* a11y: Return correct string information for item viewsIngo Klöcker2025-11-072-8/+0
| | | | | | | | | | | | | | | | | This fixes the problem that accessible name was returned as string information for all types of accessible string information (except Description), i.e. Name, Help, Value, Accelerator, etc. This made some screen readers speak the accessible name multiple times when an item view got focus. After 9fa1b691c88a4b928d3c1814a15bcab0e329222e QAccessibleTable is a subclass of QAccessibleWidget(V2) which provides suitable default implementations. Remove the override of the text() getter. Fixes: QTBUG-141051 Change-Id: I443145b97d8546fc6c80689bae50cb896e29cfd1 Reviewed-by: Michael Weghorn <m.weghorn@posteo.de> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* QSqlite: only define HAVE_LOCALTIME_R/S when using qt sqliteChristian Ehrlicher2025-11-071-2/+2
| | | | | | | | | | Be in sync with the rest of the defines which affect the sqlite source code compilation and define these two conditions only when the qt built-in sqlite is used. Pick-to: 6.10 Change-Id: I356b1a56595f496c2bb48b74cd87c085e010b9c1 Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* SQLite: Update SQLite to v3.51.0Christian Ehrlicher2025-11-074-1381/+4551
| | | | | | | | [ChangeLog][Third-Party Code] Updated SQLite to v3.51.0 Pick-to: 6.5 6.8 6.10 Change-Id: Ic72fe8779eb93093f96bcaca3532aa994b982ccc Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* Widgets: Don't implicitly fall through non-trivial casesUlf Hermann2025-11-072-0/+6
| | | | | | | | | | | | | | Otherwise the compiler complains. In one case the fallthrough was intendend. In the others the case block was newly added and not intended to fall through to the next one. Amends commit 12313f3ebe00808e9b1c27ddcb49cedf3e09582b. Pick-to: 6.10 Change-Id: Ib0d4ce0ba6ae737df93cee1c8086210a21cb5bec Reviewed-by: Marc Mutz <marc.mutz@qt.io> Reviewed-by: Wladimir Leuschner <wladimir.leuschner@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* macOS: Check entitlements directly for app sandbox detectionTor Arne Vestbø2025-11-071-46/+4
| | | | | | | | | | | | | | | Checking entitlements via the code signing verification machinery of SecStaticCodeCheckValidityWithErrors is potentially slow (may even reach out to the network, in some cases). We were mitigating this by spinning up a short lived thread to resolve the state before it was needed, but pulling the sandbox state out of the entitlements directly removes all this complexity, and is 4x faster for those times we would end up blocking waiting for the thread to finish (3-4ms vs 20ms). Pick-to: 6.10 6.8 Change-Id: I069b5bb576464b6add92dc9d37fdf116f3553d0c Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* macOS: Add private API to get a process' entitlementsTor Arne Vestbø2025-11-072-0/+16
| | | | | | | | | There's unfortunately no public API for this on iOS or other non-macOS Apple platforms. Pick-to: 6.10 6.8 6.5 Change-Id: Ib4ef0f021ae44c9df89764215bcafecc1e7c29ad Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* a11y: Make QSidebar keyboard-navigableMichael Weghorn2025-11-071-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QSidebar::selectUrl calls QItemSelectionModel::clear, which clears both, the selection and the current index. After that, it was only setting the selection, but no new current index, i.e. no entry was considered as having focus. As a result, navigating between entries using the keyboard didn't work, because the logic in QAbstractItemView::keyPressEvent/QListView::moveCursor didn't have a valid index to start from and therefore always set focus to the first entry. Fix this by also setting the current index again in QSidebar::selectUrl. Move emission of the QSidebar::goToUrl signal from QSidebar::clicked down into QSidebar::selectUrl to ensure this gets called when the URL/current index is set programatically by calling QSidebar::selectUrl directly instead of indirectly via QSidebar::clicked due to user action. (As an example, tst_QFileDialog2::task251321_sideBarHiddenEntries calls this directly, and the emulated mouse click now no longer triggers the QItemSelectionModel::currentChanged signal as the current index was already set by the previous call to QSidebar::selectUrl, and therefore the connected QSidebar::clicked slot is also no longer triggered.) Adjust the existing tst_qsidebar tests related to the QSidebar::goToUrl signal to the fact that this now gets emitted from QSidebar::selectUrl. (Since QSidebar isn't part of the public API, there's no need to keep the exact semantic of when the signal gets emitted unchanged.) Also switch the test to use PMF-style syntax to e.g. simplify finding those occurences using an IDE's "Find Usages" feature in the future. Fixes: QTBUG-141644 Change-Id: I872698de81912225cd42a5df3752d2693ac6b9ee Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Don't emit QFileDialog::directoryEntered when not changing dirMichael Weghorn2025-11-071-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | In QFileDialogPrivate::enterDirectory, return early if the directory to enter is already the current directory. This prevents emitting the QFileDialog::directoryEntered signal when no new directory was actually entered. Extend tst_QFiledialog::directoryEnteredSignal accordingly. This prepares for an upcoming fix for QTBUG-141644 where the fact that QFileDialogPrivate::enterDirectory was called again with the same path resulted in the signal getting emitted twice and therefore causing the existing QCOMPARE(spyDirectoryEntered.size(), 1); check in tst_QFiledialog::directoryEnteredSignal to fail. Task-number: QTBUG-141644 Change-Id: I3359f9f8af3ce03c7b32c040a92d4bf09e065e85 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Don't look for XDG portal support on non-Linux operating systemsTor Arne Vestbø2025-11-071-0/+4
| | | | | | Pick-to: 6.10 Change-Id: Ia181398651ad5b36286ff6c151eebe15d28bbc5f Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
* QUniqueHandler: fix build errorMårten Nordheim2025-11-071-2/+2
| | | | | | | | | An #ifdef must come after the include that defines them. Amends 52c274fa27865a0bdb20628a8c6e7d3f35fdc878. Change-Id: Ic7925e354810b4f8dafff691934af2b0777661f1 Reviewed-by: Marc Mutz <marc.mutz@qt.io>
* wasm: a11y - refactor setHtmlElementTextNameEven Oscar Andersen2025-11-072-54/+88
| | | | | | | | There are too many switches on role in this function, split the functionality into the individual handle* functions. Change-Id: I974142ba3b2fd7fb59be1ff00229f7093a0c86ed Reviewed-by: Lorn Potter <lorn.potter@qt.io>