This is the counterpart of the previous commit.
[ChangeLog][QtCore] Added QCborStreamReader and QCborStreamWriter,
classes for low-level reading and writing of CBOR streams.
Change-Id: Ia0aac2f09e9245339951ffff13c72e4bffdf4a56
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
This does not match any upstream version, but rather the "dev" branch at
https://github.com/thiagomacieira/tinycbor/. I've found myself
completely out of time to finish developing the TinyCBOR buffer
integration and zero-copy support.
Change-Id: I9741f017961b410c910dfffd150133cbf6fbe678
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
According to the documentation of ConnectNamedPipe we must pass an
OVERLAPPED object, because the passed handle was opened with
FILE_FLAG_OVERLAPPED.
Pass an OVERLAPPED object, and create a manual reset event that is
waited on if ConnectNamedPipe "fails" with ERROR_IO_PENDING.
Check the return type, and report any failure via qErrnoWarning.
Change-Id: Iedd702cecc2f0008eee6ed4f19d9370912190595
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
When a new model was set with setSourceModel() and the mapping was
built up, the destruction of the old model caused a reset in the
QSortFilterProxyModel which lead to an empty view or an assertion.
Now we properly disconnect the old model again and also clean up the old
mapping/persistent indexes when a new source model is set.
Task-number: QTBUG-44962
Task-number: QTBUG-67948
Task-number: QTBUG-68427
Change-Id: I2e0612899c210bde3ac0cfa59aefd78269deee5b
Reviewed-by: David Faure <david.faure@kdab.com>
QWindow should get an expose event before being hidden. handleExpose
iterates over the list of visible windows, so it has to be called before
the window is removed from the list of visible windows.
Change-Id: Ide920ade43c057b9aafdf9fdfa2d54d3336289d8
Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
More recent versions of Android lint triggers an error when a
translation is missing. The solution is to either provide translations
for all languages supported or add translatable="false" as property to
the strings that are not yet fully translated.
Task-number: QTBUG-63952
Change-Id: I5afa8a23d3e2285b5c93ee493d9b02397c328f2d
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Flatpak FileChooser portal doesn't support opening and exporting
directories to the sandbox as it's not technically possible. Files are
simply exported through document-portal, but directories are a different
story. We have to, in case we want to open a directory, use native file
dialog provided by platform theme we have loaded into flatpak platform
theme. Applications which need to open directories to be able to work,
like IDEs, music players, will have enabled access ho host's filesystem
anyway so it's fine to open a file dialog inside sandbox.
[ChangeLog][Linux] QFileDialog will use the native dialogs provided by
the platform theme instead of trying to use Flatpak portal to select
directories.
Change-Id: I0716193bb9878aa621b8ca88506f87c72f690887
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
A custom build of openssl can disable DES or RC2. This
allows to build Qt against those builds.
Change-Id: I9b91c943fab4d217a791381e81a7d87a9ff5031a
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Use the screen resolution obtained from QScreen instead
of QDesktopWidget.
Change-Id: If27bcf1c94a783c4c617d5364846b95a625bb93d
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
A step modifier already existed when scrolling with the
Qt::ControlModifier held. This patch applies this functionality to
other methods of stepping a spin box.
Holding the modifier increases the step rate when:
- scrolling;
- pressing the up/down keys;
- pressing the spin box up/down buttons.
[ChangeLog][QtWidgets][QAbstractSpinBox] The Qt::ControlModifier
increases the number of steps a QAbstractSpinBox takes for the
following interactions: scrolling, up/down keyboard keys and the spin
box buttons. Previously, Qt::ControlModifier only affected scrolling.
Task-number: QTBUG-67380
Change-Id: Icc8754d5c007da0771bfaef113603a2f334dd494
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
tst_QListView::horizontalScrollingByVerticalWheelEvents failed to
compile with this qmake argument.
Change-Id: I35dd4ad4c9ee92c06c94b21dd7325aee00fc98d4
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Otherwise there is a -Werror=narrowing error on big-endian
architectures (where htons does nothing).
Task-number: QTBUG-68390
Change-Id: Idb204a81aaedb9f4fde1d5fae406da36c7a1953e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Since we moved the menu items validation and target/action to
QNSView (thus relying on the responder chain), we need to take
care of case when the applications that doesn't have any window
open. By adding similar methods to QCocoaApplicationDelegate,
the last responder, we ensure the menu items will be validated
and will trigger properly. This is particularly necessary for
dock menu items, which live separately from any top-level widget.
Dock menu added to Menurama which won't quit when its last window
is closed. This way we can test that dock menu items will trigger
in the absence of any window.
Change-Id: I56d864eb9da1f8dd5adb2a3b6c3dd5304c723117
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
When multiplying a float in [0;1[ with (1<<16), with rounding, it might
end up being rounded to 65536 even if the input was under 1. This patch
uses a floor operation to make sure the value can be in a ushort, and
cleans up the surrounding code so it is clearer what it does.
Task-number: QTBUG-68360
Change-Id: I2d566586765db3d68e8e7e5fb2fd1df20dabd922
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
If LANGUAGE specified only the language, without any script or
country, and matched the value we'd got from other environment
variables, we were throwing away their knowledge of script and
country, leading to falling back on the default script and country for
that language, which might be at odds with what other environment
variables had told us.
Changed to only use LANGUAGE if it contradicts (or extends) what we
would otherwise have used. Clarified some comments in the process.
[ChangeLog][QLocale][Unix] When using LANGUAGE would lose information
about script or country, without changing language, use the locale
implied by LC_ALL, LC_MESSAGES or LANG.
Prompted-by: Safa AlFulaij <safa1996alfulaij@gmail.com>
Change-Id: Ie433e57ae6b995abafd05c931136cc9796494895
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The bounding rect was not including positive leading of the last line. This
patch solves it by changing using QTextLine's setLeadingIncluded, and adds
handling of negative leading to keep rendering unchanged in that case.
Change-Id: I4d18b81892184bb85cd7949a5dc3fb9cfa270a26
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
Use the printer's HDC instead of the screen HDC for StretchBlt().
Patch as contributed via bug report.
Task-number: QTBUG-59689
Task-number: QTBUG-66325
Change-Id: I9b5d6ddd3f0e9e68f2a003ca9ed20ece20dccef8
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Change
#include <QtCore/QDebug>
to
#include <QtCore/qdebug.h>
according to the coding style.
Change-Id: I6ba8a7424c548ddde1d18f3f6f4f87e30973d710
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Change
#include <QtCore/QDebug>
to
#include <QtCore/qdebug.h>
according to the coding style.
Change-Id: I34ddf9b9101cfbd5054584608de09de5b4b2f233
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Qt already has the widget attribute WA_StyleSheet to which indicates that
a widget was subject to a style sheet, but it doesn't indicate that the
widget was actually affected by the style sheet. For example, an application
style sheet will set the WA_StyleSheet attribute on all widgets, even if it
only targets QPushButtons. The WA_StyleSheetTarget new attribute pairs with
WA_StyleSheet to give this extra information.
[ChangeLog][QtWidgets] Added the Qt::WA_StyleSheetTarget attribute to
indicate that a widget was affected by a style sheet.
Change-Id: I7cca18ddec8fbb69f294ae2ef990672a5f4f1d83
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
Reviewed-by: Sérgio Martins <sergio.martins@kdab.com>
We require linkat(2) to materialize the file and that is (stupidly)
filtered. See 138d34b9c8 and QTBUG-64103.
Task-number: QTBUG-68344
Change-Id: I052407b777ec43f78378fffd152fd8822761b452
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Replace image and icon in the SQL Master Detail example application,
as well as the screenshot of the application on the landing page.
Task-number: QTBUG-60633
Change-Id: Ic739908b569ea7f974b9dac48f673e14f6557550
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
This fixes compilation that failed due to QOperatingSystemVersion
being undeclared. Not sure from where it was transitively included in
other builds where it apparently have worked fine though.
Change-Id: I32cfb51c4787604d456fffa7a3a8ed09952a0513
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
We need to add the \relates command otherwise it won't appear in the documentation
Change-Id: I134776c1528445761a7539cf687e4855d39eb7a7
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
On macOS the selected text was empty when run together with other tests. Change
QApplication::setActiveWindow() to QWidget::activateWindow() to get keyboard
focus as well. After that the expected temporary file name is selected.
Change-Id: I3b0c2bfca8008cb89b7e666a362beb15a851d8e0
Reviewed-by: Sami Nurmenniemi <sami.nurmenniemi@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Right now itemHasNoContents() is flaky when run together with others on macOS.
The failing assertion seems to be just checking that an effect added to an item
with the QGraphicsEffect::ItemHasNoContents flag is painted, so relax it to
allow multiple repaints.
Change-Id: Iecf445ce1bce672e7cd180a148cd53f9c60e40fe
Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
After the merger of fetch and convert, we were missing the hook
to the accelerated merged version of ARGB32->ARGB32PM conversion,
causing a minor performance regression.
Change-Id: I3965d1a95f2305306005db09640f2775aa645d2e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Turns out that the non-AVX2 code was beating the performance of the AVX2
because the simdTestMask function did a little too much. So just use the
same VPMOVMSKB technique for it.
Change-Id: I0825ff5b5f6f4c85939ffffd152f3b636ab998db
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>