qt6-bb10/tests/auto
Volker Hilsheimer 0441526448 QAIV: reset state if removing index while editing or committing
If the commit of data to a model index result in that index getting
filtered out, then the editor will be removed as part of committing the
data, and the index that the editor is associated with becomes invalid.
The subsequent call to closeEditor() will find that the index for the
editor is no longer valid.

This should not warn, and it should also not abort the clean-up process
early. Instead, identify that the editor that we want to closed is
already hidden. In that case, skip the warning and most of the cleanup
process, and proceed directly to the EndEditHint handling further down.

Add a test that simulates the two scenarios where this can happen:
either the committing of data results in the index being filtered out
by the existing filter; or the filter changes while editing, and the
index being edited gets removed. In both cases, we don't want to see a
warning, and the state of the item view should be reset correctly.

Pick-to: 6.7 6.6 6.5
Fixes: QTBUG-115765
Change-Id: If247172fdac9a1a9279dae96c078d32553d4ee5d
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
Reviewed-by: 🌴 Alexey Edelev 🌴 <alexey.edelev@qt.io>
2023-12-14 22:59:33 +01:00
..
bic/data Add binary compatibility file for 6.6.0 2023-10-17 22:23:42 +03:00
cmake Bump version to 6.8.0 2023-12-11 17:35:40 +02:00
concurrent QtConcurrent::run() test: Add tests taking static function 2023-11-09 16:52:44 +00:00
corelib QFuture: Don't use QFutureCallOutInterface for continuations 2023-12-13 21:54:00 +01:00
dbus QDBusConnectionPrivate: Close connection after failed q_dbus_bus_register() 2023-12-07 23:36:15 +01:00
gui Silence -Wbraced-scalar-init warning 2023-12-13 18:09:31 +01:00
guiapplauncher Turn the "concentriccircles" example into snippets, update screenshot 2023-12-14 20:06:32 +01:00
network Fix the qopenssl_symbols.h copy in the autotest 2023-12-13 20:54:00 +00:00
opengl tests: Remove remains of qmake conversion from CMakeLists.txt files 2023-02-17 21:56:49 +01:00
other Tests: remove blacklisted CIs no longer available 2023-12-06 22:07:44 +01:00
printsupport Dialogs: clean up native dialogs when object gets destroyed 2023-09-06 23:12:33 +02:00
shared coretext: Support variable application fonts 2023-10-03 19:25:46 +02:00
sql SQLite: Handle identifiers correctly 2023-09-28 20:51:33 +08:00
testlib Long live QDebug::operator<<(q(u)int128)! 2023-12-09 21:00:13 +01:00
tools qdbuscpp2xml: Register QtDBus metatypes 2023-11-28 13:37:56 +01:00
wasm CMake: Remove deprecated PUBLIC_LIBRARIES option in wasm tests 2023-11-29 15:00:57 +00:00
widgets QAIV: reset state if removing index while editing or committing 2023-12-14 22:59:33 +01:00
xml CMake: Make qtbase tests standalone projects 2023-07-05 15:09:32 +02:00
CMakeLists.txt CI: Enable some tests under corelib/thread for Wasm platform 2023-09-14 11:58:48 +02:00
network-settings.h QtNetworkSettings: narrow down hasIPv6 to specific OSes 2023-08-29 07:20:51 -07:00