Undo/Redo

Things you’d like to miss in the future...
Post Reply
jacky
XYwiki Master
Posts: 3106
Joined: 23 Aug 2005 22:25
Location: France
Contact:

Undo/Redo

Post by jacky »

Couple of things I noticed :

- I find it quite "odd" that we can't do nothing from the Action log. I would expect to be able to undo/redo "full power" from there... In the changelog you mention something about doing it from the AL, but how? Am I missing something here?

- I like the single/cumul/non-seq option (which I'd like to see on the Action log to be used from there, i.e. not affecting the TB setting -- that was the "full power" from above ;)) and I think it would be great to have something such as: holding Ctrl/Shift while clicking an item from the menu means Cumulative/Non-Seq.
So, when one just clicks, it does whatever the option it set to, but holding one key allows to do one operation in cumul (or non-seq) mode without the need to change the option, do it, and don't forget to set the option back! (For instance, I'd love to be in non-seq mode, but to only have one key to do a cumulative undo once in a while without the need to set/unset/reset the option)

- I find it quite annoying that the popup menu from the TB button is limited : undo or redo only. Means One needs to have two buttons to be able to do both :? This is actually really a PITA since we can't do nothing from the Action Log, once that will be changed I guess you can forget about this...

- I'd like it much better if the dates were put first on the menu/action log, and not last. Might help that I actually use a datestamp (and not the age) but I find it much easier to read that way.

- Cumulative undo: Having the list of actions about to be (un)done on the confirmation popup might be nice

- Undoing a rename operation that only changed the case (e.g. foobar to FOOBAR) fails ("rename target exists") yet the operation goes into "UNDONE" on the action log. I don't think it should be the case when the operation failed, and of course such rename shouldn't fail but change the case back.

- File|Settings: I see no "Save Action Log", and it seems that saving all settings does not affect action.dat either -- Is that normal?

- File|File Special|Swap Names isn't logged/can't be undone :(

- I know you mentioned it, but undo a "New Folder" action doesn't check that said folder it still empty. I think it might be a good idea to check/add a warning if not empty, since then we're not so much undoing creating an empty folder as we're removing other files/folders... (Same could be said for a new file).
Proud XYplorer Fanatic

graham
Posts: 457
Joined: 24 Aug 2007 22:08
Location: Isle of Man

Re: Undo/Redo

Post by graham »

Jacky said:
- I find it quite "odd" that we can't do nothing from the Action log. I would expect to be able to undo/redo "full power" from there... In the changelog you mention something about doing it from the AL, but how? Am I missing something here?
Yes, I found myself right clicking expecting an undo action - not sure about the copy bit and what it is for.

nas8e9
Posts: 2232
Joined: 21 Jun 2008 14:50

Re: Undo/Redo

Post by nas8e9 »

Would a default keyboard shortcut be a good idea? The default two seem to be Ctrl+Z and Alt+Backspace.

admin
Site Admin
Posts: 60357
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Undo/Redo

Post by admin »

Undo/Redo from action log has always been planned and still is. I just could not wait anymore and had upload something... :mrgreen:

Yes, hold shift to force cumulative and ctrl to force non-seq looks natural and was on my mind already. I found it a bit dangerous though and wrote it on the list for Undo 2.0.

Listing all cumu actions could be too much for a msgbox, and I don't see why. I mean you just have chosen to cumundo :wink: them, why show them again?

Date in front? Well, maybe in 2.0.

foobar to FOOBAR: yep, thanks!

"Save Action Log": it's always saved when you quit. XY takes care...

Swap Names: ah yes, ok!

"New Folder" action doesn't check that said folder it still empty: I actually had that code there, but then decided it was too much msgbox. I went for the recycle bin way.

admin
Site Admin
Posts: 60357
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Undo/Redo

Post by admin »

nas8e9 wrote:Would a default keyboard shortcut be a good idea? The default two seem to be Ctrl+Z and Alt+Backspace.
Already there: Default Shortcuts: Undo (Ctrl+Z), Redo (Ctrl+Shift+Z)
You must assign them in CKS... button "Default"...

nas8e9
Posts: 2232
Joined: 21 Jun 2008 14:50

Re: Undo/Redo

Post by nas8e9 »

admin wrote:
nas8e9 wrote:Would a default keyboard shortcut be a good idea? The default two seem to be Ctrl+Z and Alt+Backspace.
Already there: Default Shortcuts: Undo (Ctrl+Z), Redo (Ctrl+Shift+Z)
You must assign them in CKS... button "Default"...
I meant as part of the default set of keyboard shortcuts "out of the box", on a par with Ctrl+C,X,V. I did hit Customize Keyboard Shortcuts myself, already :) .

TheQwerty
Posts: 4373
Joined: 03 Aug 2007 22:30

Re: Undo/Redo

Post by TheQwerty »

nas8e9 wrote:I meant as part of the default set of keyboard shortcuts "out of the box", on a par with Ctrl+C,X,V. I did hit Customize Keyboard Shortcuts myself, already :) .
They are defined by default on a fresh install. If you upgrade XY won't add them to avoid re-assigning a shortcut you are already using elsewhere.

You can have XY assign any unused shortcuts to their default commands by using "Options->Reset Unused Shortcuts to Defaults" in the CKS dialog.

nas8e9
Posts: 2232
Joined: 21 Jun 2008 14:50

Re: Undo/Redo

Post by nas8e9 »

Thank you for expanding "Already there" :D. I noticed Ctrl+Alt+Z is by default assigned to the Action Log.

jacky
XYwiki Master
Posts: 3106
Joined: 23 Aug 2005 22:25
Location: France
Contact:

Re: Undo/Redo

Post by jacky »

admin wrote:Listing all cumu actions could be too much for a msgbox, and I don't see why. I mean you just have chosen to cumundo :wink: them, why show them again?
Just seemed like a nice reminder, as well as consistency with the confirmation popup one might get (depending on the option set) for non-cumul undo which does include the action about to be undone.
And if the list might be too long, I say it'd be fine having only the two first & two last actions or something, just something a little more than a number...
admin wrote:"Save Action Log": it's always saved when you quit. XY takes care...
I see. Well, I feel it'd be a good idea to have it saved on Save All Settings, especially for all the cases when XY doesn't end as expected...
admin wrote:"New Folder" action doesn't check that said folder it still empty: I actually had that code there, but then decided it was too much msgbox. I went for the recycle bin way.
Well, I'm not a fan of popup either but I think the popup way would be better here. Because undoing the creation of a folder and removing a folder full of content are two different things, and in some situations I'm sure one could have liked a life-savior confirmation popup (as such an "undo" can be triggered on one click/KS without any popup/confirmation).
Besides, the recycle bin way is one (optional) way, but also one not reliable -- depending on a few things (e.g. size), items might simply not (all) be sent to the bin.

Tiny thing: go to Action log, select e.g. a rename job, and press Clear. The list (old/new names) are not cleared.

Lastly: Once again, you did a very fine job with this feature, both in its implementation & the GUI that goes with it. Well done, sir!
Proud XYplorer Fanatic

admin
Site Admin
Posts: 60357
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Undo/Redo

Post by admin »

jacky wrote:
admin wrote:"New Folder" action doesn't check that said folder it still empty: I actually had that code there, but then decided it was too much msgbox. I went for the recycle bin way.
Well, I'm not a fan of popup either but I think the popup way would be better here. Because undoing the creation of a folder and removing a folder full of content are two different things, and in some situations I'm sure one could have liked a life-savior confirmation popup (as such an "undo" can be triggered on one click/KS without any popup/confirmation).
Besides, the recycle bin way is one (optional) way, but also one not reliable -- depending on a few things (e.g. size), items might simply not (all) be sent to the bin.
OK, I agree. This concerns only undo of "New", right? Now how to call this checkbox? Hmmm... maybe I chicken out and just add a tweak that is ON be default: PromptOnUndoingNonEmptyNew=1

EDIT: it's ok, all done. 8)

admin
Site Admin
Posts: 60357
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Undo/Redo

Post by admin »

jacky wrote:
admin wrote:Listing all cumu actions could be too much for a msgbox, and I don't see why. I mean you just have chosen to cumundo :wink: them, why show them again?
Just seemed like a nice reminder, as well as consistency with the confirmation popup one might get (depending on the option set) for non-cumul undo which does include the action about to be undone.
And if the list might be too long, I say it'd be fine having only the two first & two last actions or something, just something a little more than a number...
Agreed, and it's a convincing way to express the heaviness of the situation. :)

jacky
XYwiki Master
Posts: 3106
Joined: 23 Aug 2005 22:25
Location: France
Contact:

Re: Undo/Redo

Post by jacky »

Looks good. Although, I still find it quite odd/unexpected that when I go to undo something (e.g. creating a new folder now not empty) and then, on the confirmation popup, change my mind, the operation still goes as if in the Action log, in that if after that say I check and now want to undo it for sure, it's just not on my undo list anymore, it moved up. It's something that, IMO, seems pretty odd, just like this one, hitting Redo:
XYplorer wrote:This action cannot be redone because it has not been undone.

New File "New Textfile.txt" (20/10/2009 14:08:23)
I would have expected that action to remain on my "undo list" in the action log, since I aborted/canceled the undoing.


Also, if one run a script such as

Code: Select all

copyto '.', "<xypath>\*.exe";
then the AL shows this:
Copy "*.exe" to "V:\tmp\" (20/10/2009 14:16:42)
Which I guess is okay, but on the list below that actually lists the items copied, I would have expected to get the actual items that were copied, and not again one item reading "*.exe" -- Just like I would expect the undo to be applied to those items only, and not whatever matches *.exe in what was the destination of the original copy operation (where there could have been other items matching), which could be feared right now with a "*.exe" listed, although in reality XY doesn't seem to do at all anything when undoing such an operation.
Proud XYplorer Fanatic

admin
Site Admin
Posts: 60357
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Undo/Redo

Post by admin »

jacky wrote:Looks good. Although, I still find it quite odd/unexpected that when I go to undo something (e.g. creating a new folder now not empty) and then, on the confirmation popup, change my mind, the operation still goes as if in the Action log, in that if after that say I check and now want to undo it for sure, it's just not on my undo list anymore, it moved up. It's something that, IMO, seems pretty odd, just like this one, hitting Redo:
XYplorer wrote:This action cannot be redone because it has not been undone.

New File "New Textfile.txt" (20/10/2009 14:08:23)
I would have expected that action to remain on my "undo list" in the action log, since I aborted/canceled the undoing.


Also, if one run a script such as

Code: Select all

copyto '.', "<xypath>\*.exe";
then the AL shows this:
Copy "*.exe" to "V:\tmp\" (20/10/2009 14:16:42)
Which I guess is okay, but on the list below that actually lists the items copied, I would have expected to get the actual items that were copied, and not again one item reading "*.exe" -- Just like I would expect the undo to be applied to those items only, and not whatever matches *.exe in what was the destination of the original copy operation (where there could have been other items matching), which could be feared right now with a "*.exe" listed, although in reality XY doesn't seem to do at all anything when undoing such an operation.
1. What would be the alternative? If I "leave it in the Undo list" I could not move anymore backwards through the action history. The Undo button has 2 functions at the same time: Undo the last version AND move back one step in the action list. This might be a problem but I don't see another solution.

2. True, a problem. But in this case "*.exe" is never resolved under my eyes but directly passed to the shell. That's why no filenames are present in the log: I simply don't know them and the shell does not tell me. I will stamp such actions (= actions with wildcards) as non-un/redoable because as you say, the undo/redo could be anything depending on the current location.

jacky
XYwiki Master
Posts: 3106
Joined: 23 Aug 2005 22:25
Location: France
Contact:

Re: Undo/Redo

Post by jacky »

admin wrote:1. What would be the alternative? If I "leave it in the Undo list" I could not move anymore backwards through the action history. The Undo button has 2 functions at the same time: Undo the last version AND move back one step in the action list. This might be a problem but I don't see another solution.
Yes, I expected that given how the single (non-seq) mode, and I'd agree for when, to the confirmation, I say "No". But if I click on Cancel I would then expect the undoing to be aborted, plain & simple, with nothing done (inc. to the AL). Right now whether I click No or Cancel the action always "moves up" in the log, which I don't think should be the case when I Cancel.
Proud XYplorer Fanatic

admin
Site Admin
Posts: 60357
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Undo/Redo

Post by admin »

jacky wrote:
admin wrote:1. What would be the alternative? If I "leave it in the Undo list" I could not move anymore backwards through the action history. The Undo button has 2 functions at the same time: Undo the last version AND move back one step in the action list. This might be a problem but I don't see another solution.
Yes, I expected that given how the single (non-seq) mode, and I'd agree for when, to the confirmation, I say "No". But if I click on Cancel I would then expect the undoing to be aborted, plain & simple, with nothing done (inc. to the AL). Right now whether I click No or Cancel the action always "moves up" in the log, which I don't think should be the case when I Cancel.
Ah oui, bien sur!

Post Reply