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>
Windows 10 windows contain an invisible area within the NC window frame
on which the mouse cursor is enabled to perform resizing. This change
captures the geometry of the invisible margins and considers it when
moving a window, so that, for instance, a move(0,0) does not generate
gap between the window and the beginning of screen.
[ChangeLog][Windows] The dimensions of invisible margins inside the
frames of Windows 10 windows will now be disregarded in the positioning
of Qt windows to avoid a misplaced look (offset by a few pixels from
the expected position).
Task-number: QTBUG-55762
Change-Id: I1f537756eb1a093f78b919de9d44992528199700
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Replace the XML pages which are typically displayed as broken
by the XTHML pages. Strip some suffixes.
Change-Id: Idf2b9706f169484c659582a1a2d38904d5dd81aa
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Wait for the spinbox to show become active in the previous test. Also use
QWidget::activateWindow() instead of QApplication::setActiveWindow(). Use of the
latter seemed to result in some confusion where QWidget::isActiveWindow()
returned true but QWindow::isActive() on the underlying window returned false,
leading qWaitForWindowActive() to fail.
Also remove superfluous setting of focus. It was just set and verified.
Change-Id: I023cdc2d272e23b2537b32606b7a3bf35bf671ac
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
[ChangeLog][QtCore][QSharedPointer] Fixed a problem that made create()
on a type with const qualification fail to compile.
Task-number: QTBUG-68300
Change-Id: I0825ff5b5f6f4c85939ffffd152f3e55e5b9caae
Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
When moving a window by dragging the title bar, no WM_NCLBUTTONUP is
received after WM_NCLBUTTONDOWN, WM_NCMOUSEMOVE (due to internal mouse
capture), which can leave the left mouse button 'pressed' in
QGuiApplication's state. Intercept WM_EXITSIZEMOVE to sync the buttons.
Complements 4589440891.
Change-Id: I94d18d1d4a4796dcecb1a9731809d05c7f9ddd65
Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
This accounts for a case of a placeholder being duplicated in the
prepare query, but where only one placeholder was used. This amends
e4e87a2ece
Task-number: QTBUG-68299
Change-Id: Ia92ee912facd51a13e7222886debb219b24442b0
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Revert a part of af5c8d04fb
which affected mouse wheel event redirection.
Task-number: QTBUG-63979
Change-Id: Ice88675aadbb8a7477b3758a607db5979d62562c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Alexandra Cherdantseva <neluhus.vagus@gmail.com>
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Send changed events from QPlatformWindow::initialize()
synchronously so a protentially changed screen takes
effect in QWindow::resize() called by QWidget::show_sys().
Task-number: QTBUG-67777
Change-Id: I889500d458caf0e782bdbc237ce790f0b0bc2d95
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Instead of two 16-byte loads, if AVX2 is present. Otherwise, it's
exactly the same.
Because of the way the SIMD instructions were extended to 256-bit in
AVX2, we gain nothing doing two 32-byte loads, aside from the loop
unrolling.
Change-Id: Ib48364abee9f464c96c6fffd152e531925814ac2
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
This instruction is somewhat slow and requires a lot of inputs to be
correctly set. Instead, use the PMIN trick, which does have unsigned
comparison support.
This commit moves the helper function to a lambda inside qt_to_latin1,
to make it easier to reuse the constants in the next commit and to avoid
warnings of unused static functions.
Change-Id: Ib48364abee9f464c96c6fffd152e9e84f4ad3ae8
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
setAutoRepeat() is failing on macOS and Windows when run together with
defaultAndAutoDefault(). It succeeds when run on its own. Adding the wait allows
it to succeed when run with the other tests as well.
Amends 0cb940b1d3, which removed the wait.
The comment is the same as before. I couldn't see a better way to replace the
wait (QApplication::topLevelWidgets() already returns only the testWidget and
testWidget->isActiveWindow() returns true).
Another theory I had was something waiting for the KeyRelease so I changed
QApplication::sendEvent() uses to QTest::keyClick(). It did not help but that
still seems preferable.
Change-Id: If87d1e6e018751f3068ea4c913ae6731aba41ff0
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
dialogs/qprintdialog_unix.cpp:149:15: error: private field 'm_printer' is not used [-Werror,-Wunused-private-field]
QPrinter *m_printer;
^
Change-Id: Idce515a3e66019756b6ad2d305072e0a89bb823b
Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
If the input is already known to be Latin 1, we don't need to check and
merge in question marks. QJsonObject already needed this code, now we
can make it more efficient.
I'll need the same code in CBOR.
Change-Id: Ib48364abee9f464c96c6fffd152e508f078404e5
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
We don't have _mm_cvtsi64_si128() (the REX.W expansion of MOVD [0F 6E]),
but we do have _mm_loadl_epi64(), the SSE2 expansion of the MMX MOVQ at
opcode 0F 7E. Ditto for _mm_cvtsi128_si64() and _mm_storel_epi64(). And
those work even in 32-bit mode. By doing this, we can reduce the tail
unrolled loops by half, reducing code size.
I'm not adding these new SIMD sections to -Os builds.
Change-Id: Ib48364abee9f464c96c6fffd152e405310ef67be
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Improves performance a little. This is just because I can and the
function is right there for the taking, as this qt_urlRecodeByteArray
function is only used in deprecated QUrl code.
Change-Id: I5d0ee9389a794d80983efffd152d290e570af387
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
We can just reuse the code I added for QtPrivate::isAscii(), adding the
update to the ptr parameter in the failed case.
Change-Id: I5d0ee9389a794d80983efffd152d277e2adf444d
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Use new helper functions for mouse events and buttons
Change-Id: Idb74fbd4ffde0c22b3d4bbddb5761567081bdf7c
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
First of all, this removes the UB that used to try and calculate the
distance between the two strings. That's a valid technique in assembly,
but dangerous in C++ and totally unnecessary. The compiler is perfectly
able to generate loops with a single induction variable all on its own.
Second, this commit makes the main loop use 32-byte comparisons (16
characters at a time), which is a reasonable size for strings. We use
AVX2 if that's available, or an unrolled pair of 16-byte loads
otherwise. After the existing 16-byte comparison, this commit inserts an
8-byte (4-character) comparison and then reduces the final, unrolled
comparison to just 3 characters.
Change-Id: Ib48364abee9f464c96c6fffd152e474b39e1f293
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
std::unary_function and std::binary_function are gone. Remove their
uses.
Change-Id: I5d0ee9389a794d80983efffd152c96f0f2149b40
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Starting with QtCreator 4.6.1* we introduce a new way to debug Qt on Android apps,
which doesn't need this support anymore.
Of course to debug Qt 5.12+ the user must use QtCreator 4.6.1+
* 429c596395697ff3533e679a848ad26cd1ee97cb
[ChangeLog][Android] Remove old debugging way. To be able to debug Qt on Android apps
the user must use QtCreator 4.6.1+
Change-Id: I16d08312628c9afb7cfa47eb906b25a87af5ba55
Reviewed-by: hjk <hjk@qt.io>
[ChangeLog][QtCore][Global] Added the QT_TR_N_NOOP(),
QT_TRANSLATE_N_NOOP(), and QT_TRANSLATE_N_NOOP3() macros for numeral
dependent delayed translation.
Change-Id: I57c5b1ad4006267f49a57b0cbc40216b8e0399ff
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Martin Smith <martin.smith@qt.io>
Fixes build with -no-feature-library, because the qlibrary.h header
contains QT_REQUIRE_CONFIG(library).
Change-Id: If64ece8bd77e8824b86dc91f95dd9062cb2a1644
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
Filters are usually in format (Name (*.foo *.bar)), but valid filter is
also (Name ( *.bar *.foo )), containing additional spaces. When we split
content in the brackets divided by spaces, there will be then empty
strings which we need to filter out, otherwise the result we send over
DBus is not valid.
Change-Id: Iaa265189408f47324bc9b269d534bf4c8d7d2cae
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
QDialog::exec() has a number of problems due to spinning an inner
event loop (to counteract its being synchronous). We've had
QDialog::open() as a better alternative for a long while now,
so encourage people to use that instead.
Change-Id: I51a69a018dcbf6133adb6c2f69c7caf442008b36
Reviewed-by: Martin Smith <martin.smith@qt.io>
Add a scaling overlooked in 63d08003cf.
Task-number: QTBUG-68194
Change-Id: I97c771435e4316ec55aacc527335b62cb4dfd9ec
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
QTableModel::setItemData() did not treat Qt::EditRole and
Qt::DisplayRole as the same. This lead to inconsistencies between
setItemData() and QTableWidgetItem::setData()
[ChangeLog][QtWidgets][QTableWidget] Fix handling of Qt::EditRole and
Qt::DisplayRole in setItemData().
Change-Id: I456f4c8e654de701dcd579236162b8aaa8ba1e53
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Invalid syntax due to missing closing brackets and
exception not being handled when calling .close()
on a stream.
Change-Id: If8f191fbc44fe1b031fd86abff5163bca434156a
Reviewed-by: BogDan Vatra <bogdan@kdab.com>