Developer forums (C::B DEVELOPMENT STRICTLY!) > Plugins development
"Auto restore" feature for autosave plug-in?
Pecan:
--- Quote from: thomas on January 17, 2007, 01:23:12 pm ---The idea as such is good, I'll think about how it can be implemented.
--- End quote ---
I'm be interested also. Especially since the keybinder ini file can become corrupt during a crash while keybinder is doing a dynamic menu merge.
Can I ape your code?
Game_Ender:
Do most crashes result in the "lock file" being left behind? If so here is my solution: If CB starts up and sees the lockfile still in place then it searches for all .bak files in the project it was last using (should be the most recently project). If any of those .bak files have newer timestamps times than actuall file you know that the editor was closed while the user was still editing a file. You can then prompt the user and restore the file.
eranon:
Does this feature (ability to autorestore or, even, manually from within C::B) implemented since 2007... I don't see it.
Also, I've noticed if you choose the option to save as original files (so, overwrite them), C::B still show the "*" beside filenames on its editor tabs. It would be smart that the autosave plugin warns C::B about external change (or do C::B considers the action of autosave as an internal save).
Third, it could be useful to have an option "save in a subdirectory" (using original filenames) : this way, external restore by hand will be just a simple copy, accepting the overwriting warning from OS. Just an idea.
thomas:
I've completely forgotten about that feature, mostly because Code::Blocks didn't crash since approx. 2008 (which kind of makes autosave kind of superfluous) :P
Uh... time... let me see if I find time for this, maybe between christmas and new year.
oBFusCATed:
--- Quote from: eanon on August 30, 2012, 12:13:31 am ---Also, I've noticed if you choose the option to save as original files (so, overwrite them), C::B still show the "*" beside filenames on its editor tabs. It would be smart that the autosave plugin warns C::B about external change (or do C::B considers the action of autosave as an internal save).
--- End quote ---
But it does just this, save the original file and the state of the file is set to not modified and the '*' is removed. I use this feature every day and I know it works.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version