| Summary: | Preserve item selection when resorting columns in Table View (Album tab) | ||
|---|---|---|---|
| Product: | [Applications] digikam | Reporter: | zroutik |
| Component: | Albums-TableView | Assignee: | anamaynarkar <anamay.narkar.102> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | anamay.narkar.102, caulier.gilles |
| Priority: | NOR | ||
| Version First Reported In: | 9.0.0 | ||
| Target Milestone: | --- | ||
| Platform: | Ubuntu | ||
| OS: | Linux | ||
| Latest Commit: | https://invent.kde.org/graphics/digikam/-/commit/24e1beccbc041da773da0f0f197308968e98a812 | Version Fixed/Implemented In: | 9.1.0 |
| Sentry Crash Report: | |||
|
Description
zroutik
2026-01-03 19:29:34 UTC
I confirm the table view selection lost at column sort change under macOS Git commit 24e1beccbc041da773da0f0f197308968e98a812 by Gilles Caulier, on behalf of Anamay Narkar. Committed on 18/03/2026 at 21:19. Pushed by cgilles into branch 'master'. Bug: 514121: TableView: preserve selection when resorting columns When sorting by a column header, TableViewModel::sort() calls beginResetModel which causes the selection state to be reset. Fix by connecting to modelAboutToBeReset and saving the selected image Ids before the clear occurs. The restore is deferred by one tick to allow image model to finish resetting before looking up new row positions by Id. M +110 -2 core/app/views/tableview/tableview_selection_model_syncer.cpp M +3 -1 core/app/views/tableview/tableview_selection_model_syncer.h https://invent.kde.org/graphics/digikam/-/commit/24e1beccbc041da773da0f0f197308968e98a812 |