Scenario: 1. Locate a directory with a lot of files (so that vertical scrollbar appears) 2. Navigate to a file somewhere in the middle of the list (for better illustration of the probelm scroll to the middle of the list and choose a file displayed somewhere in the middle of a display) 3. Delete this file using keyboard key ('Delete'). Expected result: file should be deleted and focus (by focus I mean the blue line highlighting the currently selected file) shift to the nearest remaining file (typically file above the deleted one) Actual result: focus disappears, and when you press 'Up' or 'Down' key, list of files is scrolled to the beginning of the list and focus appears on the first file in the list. The problem appeared in Thunar 1.6. In older version (for example in 1.2.3) the result of a file deletion was as expected.
In 1.6.2, Thunar is behaving the way you expect. If I select a file, press delete, and then press an arrow key, the adjacent file is then selected.
% pacman -Q thunar thunar 1.6.3-1 Sorry, it’s not.
I also tried it against thunar built from master and from the 1.6.3 package. It seems to work as expected. Profpatsch: What version of gtk do you have installed? I have 2.24.10.
% pacman -Q gtk2 :( gtk2 2.24.20-1 % pacman -Q gtk3 gtk3 3.8.2-1
I did some more testing for this with Thunar 1.6.3. This does not happen (for me) in the Icon View or the Compact List View, but does happen in the Detailed List View.
Hm, but I am in Detailed List View.
Sorry, I mixed it up. It works in Compact List, not in Detailed List, just as you said.
This bug appears directly related to https://bugzilla.xfce.org/show_bug.cgi?id=10558 "when renaming a file the selected file does not follow the renamed file (or so it seems)"
*** Bug 11640 has been marked as a duplicate of this bug. ***
Not exactly sure if I'm fitting here, but my problem seems similar (symbolic view) Sometimes on deletion (also had on copy and paste actions) thunar jumps the displayed view Testbed: Folder with many files (a need to scroll) If I'm in this folder and then the files appear, thunar behaves like it should (or on a new session and first entry). File gets deleted, window position doesn't jump. Moving a folder up and then back, Thunar jumps to the last saved (scrollbar-)position. If I now delete files thunar jumps back to this saved position.
Hmm.. it appears to me I should have posted this in #10756 Sorry for the noise
Moved from bug 10306 >I built against gtk3 >When you delete a file in the middle of a long list, with the delete key, in "detailed list view", and then press the arrow keys to move to a next position in the list, the cursor jumps to the very top of the window, and you have to scroll all the way down again to where you were at the moment of the deletion. >I propose that after deleting the cursor in the list should jump to the previous item. I can confirm this happens in Detailed List view in Thunar 1.6.3-2 on Debian
*** Bug 10306 has been marked as a duplicate of this bug. ***
This bug is still there in 1.6.10 , extremely annoying when doing actual file management.
Confirming this bug in 1.6.10 in detailed view mode: after deletion pressing Up/Down resets position to beginning. Yes, it's very annoying.
Thunar-1.6.10. After deletion a file resetting point to the first item makes Thunar poorly usable with keyboard interface, especially in the mid-end of large file list.
Created attachment 6836 Restore focus on nearest remaining file after deletion when using detailed list view Hi all, Please feel free to let me know if this fixes the issue for you, and how to possibly improve it. Thanks!
> Please feel free to let me know if this fixes the issue for you, and how to possibly improve it. It fixes the bug that it loses focus completely, but it’s not yet how I would expect it to behave: Right now if it looks like 1 2 3
Sorry, hit save too early. Again: > Please feel free to let me know if this fixes the issue for you, and how to possibly improve it. It fixes the bug that it loses focus completely, but it’s not yet how I would expect it to behave: Right now if it looks like 1 2 << 3 when I delete 2 the result is 1 < 3 It jumps back on entry and loses full focus, having only a hollow focus. As a user I often want to delete multiple consecutive files one after the other, so my expected result would be: 1 3 << with a full focus on 3, so I can directly handle the next file.
Created attachment 6843 Restore focus on nearest file *after* deleted files Sorry, you are right, the previous patch would focus the nearest file _before_ the deleted file(s), instead of the one after. This patch should fix this. > and loses full focus, having only a hollow focus. This is the way Thunar currently works in icons and compact list views, which is why I've kept this behaviour. Incidentally, I find it more intuitive: a hollow selection makes it clearer to me that files have been deleted, especially in a folder with a large number of files and when simply trashing files (which, contrary to permanent deletion, does not trigger a warning pop-up). Of course, this is just my personal preference and irrelevant here, but I guess it _might_ be a reason why it was done this way in the first place.
The position problem is fixed, if the hollow markings are thunar default behaviour I think this issue is fixed. :+1:
Ping. Could someone review the patch, please?
(In reply to Michał Górny from comment #22) > Ping. Could someone review the patch, please? Hi guys, I can confirm this patch #6843 is working as expected on top of Thunar-1.6.10 I applied the patch and recorded a video showing the issue fixed: https://filiperosset.fedorapeople.org/rawhide/video-bug-9870.mkv.tar.gz [filiperosset@rosset-laptop ~]$ rpm -q Thunar Thunar-1.6.10-7.fc26.x86_64 [filiperosset@rosset-laptop ~]$ rpm -q gtk2 gtk2-2.24.31-2.fc25.x86_64 [filiperosset@rosset-laptop ~]$ rpm -q gtk3 gtk3-3.22.2-1.fc25.x86_64
Sorry for the late replay and thanks for the patch ! Actually I just wanted to test and possibly apply the patch .. however it looks like thunar-master already handles the use-case correct without the patch. I have no glue why this is the case. I can however reproduce the problem with thunar 1.6.13
When applied to 1.6.13 the patch lacks some features which the current master has ... e.g. keeping the focus on the last file. In the patch no file is focused after delete. First up/down has to be pressed to regain focus and delete the next file .. that's a bit irritating. And still a beep sound is played. Since master does not suffer from this bug, I will close the report now. Hopefully we can release thunar 1.8 soon.