Bug 481717

Summary: After renaming, the file should be immediately selected
Product: [Applications] dolphin Reporter: Jin Liu <ad.liu.jin>
Component: view-engine: generalAssignee: Dolphin Bug Assignee <dolphin-bugs-null>
Status: RESOLVED FIXED    
Severity: minor CC: dougshaw77, kfm-devel
Priority: NOR Keywords: qt6
Version: unspecified   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Jin Liu 2024-02-23 11:35:26 UTC
SUMMARY
Currently, there is ~2 seconds delay between renaming and the file is re-selected. This is quite annoying when I try to rename a file then cut it - pressing Ctrl-x too quickly would trigger the multi-selection mode.

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 5.93.0
KDE Frameworks Version: 5.249.0
Qt Version: 6.6.2
Kernel Version: 6.7.5-arch1-1 (64-bit)
Graphics Platform: Wayland
Processors: 12 × AMD Ryzen 5 5600H with Radeon Graphics
Memory: 13.5 GiB of RAM
Graphics Processor: AMD Radeon Graphics
Comment 1 Doug 2024-02-24 07:46:19 UTC
Can reproduce.

Operating System: KDE neon Testing Edition
KDE Plasma Version: 6.0.0
KDE Frameworks Version: 6.0.0
Qt Version: 6.6.2
Kernel Version: 6.5.0-21-generic (64-bit)
Graphics Platform: Wayland
Graphics Processor: AMD Radeon Pro WX 3200 Series
Comment 2 Bug Janitor Service 2024-10-11 06:48:26 UTC
A possibly relevant merge request was started @ https://invent.kde.org/system/dolphin/-/merge_requests/839
Comment 3 Jin Liu 2024-10-12 14:02:58 UTC
Git commit 1ba5168e39b270744a8e5c033ec24900b337f908 by Jin Liu.
Committed on 12/10/2024 at 13:23.
Pushed by meven into branch 'master'.

dolphinview: when rename dialog finishes, immediately update the model and the selection

On sucessful return of the rename dialog, we update
the model and the selection immediately to reflect
the new name. This is to avoid the short duration
after the rename during which the selection is lost.

Currently, after the rename dialog finishes, the selection
is briefly lost for about 1 second until the view
automatically refreshes.

This patch updates the model and selection immediately
after the dialog finishes, so the renamed file is still
selected.

M  +14   -6    src/views/dolphinview.cpp
M  +0    -1    src/views/dolphinview.h

https://invent.kde.org/system/dolphin/-/commit/1ba5168e39b270744a8e5c033ec24900b337f908
Comment 4 Jin Liu 2024-10-12 14:03:04 UTC
Git commit a340362524b5979474bb55705e37f40ba89f6f5b by Jin Liu.
Committed on 12/10/2024 at 13:17.
Pushed by meven into branch 'master'.

dolphinview: after inline renaming, immediately update the selection

Currently, the inline renaming updates the model and
the list of selected files (m_selectedUrls) immediately
after the user presses enter, but the selection in the
view is not immediately updated. This results in the
selection to be briefly lost for about 1 second until
the view automatically refreshes.

This patch updates the selection immediately after
the user presses enter, so the renamed file is still
selected.

M  +1    -0    src/views/dolphinview.cpp

https://invent.kde.org/system/dolphin/-/commit/a340362524b5979474bb55705e37f40ba89f6f5b