SolveSpace Logo SOLVESPACE -- parametric 2d/3d CAD
Examples
Tutorials
Features
Download
Reference
Technology
Library
Forum
Contact
USER FORUM

(you are viewing a thread; or go back to list of threads)

Autosave (by yugami)
I implemented a basic autosave feature (last night I lost a bunch of work because of a forced reboot and my poor saving habits).

I kept it as platform agnostic as possible tying into a windows timer and 1 message box based on the existing codebases use of these features.

If an autosave file exists (saves in the same directory with .auto appended) it will detect this and ask if you would prefer to open this instead. If an autosave file is loaded save will detect this and remove the .auto when you save next. Saving deletes the current .auto file from the directory as well.


Limitations:
Only works on projects with a file name. Anything new and unsaved this overlooks.

Currently hard coded to 5 minutes. Timer is setup in AfterNewFile. Maybe want to make this an adjustable feature.

Saves using the internal SaveFile logic that can throw an error window if the drive goes missing.

Windows only (I haven't looked at any of the linux code) but it uses a timer similar to the tooltip logic so the linux guys should be able to reproduce easily.

I will be submitting this through git for the owner to review.
Sat Mar 21 2015, 22:40:58
Post a reply to this comment:
Your Name:
Your Email:
Subject:
(no HTML tags; use plain text, and hit Enter for a line break)
Attached file (if you want, 5 MB max):
© 2008-2022 SolveSpace contributors. Most recent update June 2 2022.