Review Request 128563: Preserve selected items when changing folders

Emmanuel Pescosta emmanuelpescosta099 at gmail.com
Sun Feb 26 21:07:25 GMT 2017



> On Jan. 29, 2017, 3:49 p.m., Emmanuel Pescosta wrote:
> > I hope that this is more understandable than my previous attempt.
> 
> Martin Tobias Holmedahl Sandsmark wrote:
>     It's a long time since I wrote this patch now so I don't remember all the details. But I went through several iterations before I found something that worked, including most of what you have suggested. I'm fairly sure this is the best solution short of a more major refactoring.
> 
> Emmanuel Pescosta wrote:
>     This RR can now be closed, fixed in [1].
>     
>     I have found some problems with your patch (e.g. restore the selection when not all items are available immediately when using sftp or other slow ioslaves). 
>     I did some cleanups [1] and now it's possible to make use of the partial selection restoring of DolphinView::updateViewState without duplicating the code.
>     
>     I have also fixed the anchored selection bug you have mentioned, see [3]. Because of the refactoring this also fixes the same bug when reloading (F5) the current view.
>     
>     [1] https://cgit.kde.org/dolphin.git/commit/?id=8bc6d09c57eb0a976e9b4f9ee002a48664dfe277
>     [2] https://cgit.kde.org/dolphin.git/commit/?id=41b0e4297313b6549f9178c77c30101a42b0525f
>     [3] https://cgit.kde.org/dolphin.git/commit/?id=1d0b6ba65ff625245c40be0c94cf1ed0c780792e
> 
> Martin Tobias Holmedahl Sandsmark wrote:
>     Tested git from master, and selection is not preserved when going back or forward in history nor is it possible to select anything (with shift + arrow key) after going back or forward without changing selection.
>     
>     When reloading the selection is preserved, but it isn't possible to change selection with shift + arrow keys.

This is strange. Selection preserving and select with shift+arrow keys works fine here.

Tested by:
* Going back and forward (gui, mouse buttons, keyboard shortcuts)
* Closing a tab and reopening it
* Reloading

> When reloading the selection is preserved, but it isn't possible to change selection with shift + arrow keys.

Are you sure that you are using the correct executable? What you describe here sounds like the old behavior of reload. If this is really the patched version, then the anchored selection must have a bug because the anchored selection is always enabled before items are selected (see 1).

Does closing a tab and then reopening it correctly restore the previously selected items?

[1] https://cgit.kde.org/dolphin.git/commit/?id=1d0b6ba65ff625245c40be0c94cf1ed0c780792e


- Emmanuel


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/128563/#review102312
-----------------------------------------------------------


On Dec. 11, 2016, 1:38 p.m., Martin Tobias Holmedahl Sandsmark wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/128563/
> -----------------------------------------------------------
> 
> (Updated Dec. 11, 2016, 1:38 p.m.)
> 
> 
> Review request for Dolphin, David Faure, Elvis Angelaccio, Emmanuel Pescosta, and Sune Vuorela.
> 
> 
> Repository: dolphin
> 
> 
> Description
> -------
> 
> Instead of just clearing the selection when going back and forth in history, it now preserves the selected items.
> 
> Another bug it fixes is if you enter a folder, go back, and then hold down shift and press an arrow key to try to select something.
> 
> 
> Diffs
> -----
> 
>   src/dolphinviewcontainer.h 62f9110 
>   src/dolphinviewcontainer.cpp 1c43fc9 
>   src/views/dolphinview.cpp a737dd0 
> 
> Diff: https://git.reviewboard.kde.org/r/128563/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Martin Tobias Holmedahl Sandsmark
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.kde.org/mailman/private/kfm-devel/attachments/20170226/204218a5/attachment.htm>


More information about the kfm-devel mailing list