35 Commits

Author SHA1 Message Date
David Capello
1ac3148f72 Don't show full path on Data Recover view if the user wants to hide them 2019-05-31 09:42:08 -03:00
David Capello
93fe19d353 Use cancelable async tasks to load/delete backup sessions 2019-05-30 23:17:13 -03:00
David Capello
1b62515cd2 Add "Recover Files..." option in Home tab
We've changed the way the "recover files" option works:
* Now it's an option that is always available (so we can open files
  even from sessions that were correctly closed in the past)
* We can open sessions from other Aseprite versions (as in a "best
  effort" approach, if it works, ok, if it doesn't -> contact user
  support)
2019-05-27 23:53:57 -03:00
David Capello
865e0d7ee6 Add some separators for session date and time
From: https://community.aseprite.org/t/2276
2018-11-26 13:26:11 -03:00
David Capello
81965b904f Use current working color space in new created files
* Added the gfx::ColorSpace field in doc::ImageSpec
* Removed some methods like Sprites::add(width, height, etc.)
* Prefer methods with ImageSpec as argument (which now includes the color space)
2018-10-25 15:23:01 -03:00
David Capello
f2ed45e795 Replace base::UniquePtr -> std::unique_ptr 2018-08-08 17:27:26 -03:00
David Capello
8d3da46ac9 Rename DocumentReader/Writer -> DocReader/Writer 2018-07-14 22:49:22 -03:00
David Capello
9c79ea2b77 Rename app::Document -> Doc 2018-07-07 11:54:44 -03:00
David Capello
6b1c884eb5 Add code to check integrity of backups 2018-07-04 12:35:15 -03:00
David Capello
d0c9266eaf Merge branch 'master' into beta 2016-11-09 18:49:56 -03:00
David Capello
d6f2bec3fe Unlock document from backup thread when UI needs it
Added a new "weak lock" concept to RWLock/Document class. The background
thread that saves data recovery information can obtain this "weak lock"
which can be unlocked by the UI thread in any moment (i.e. when the user
needs the document immediately for UI.)
2016-11-09 17:22:55 -03:00
David Capello
5c3f75c64b Merge branch 'master' into beta 2016-11-07 18:17:42 -03:00
David Capello
644b8ff0a4 Add Ctrl+Shift+R on debug mode to recover the active document from active backup session
In this way we can test on each moment how the information is being
saved and will be recovered. We can find bugs with missing or invalid
doc::Object::incrementVersion() calls.
2016-11-07 17:47:53 -03:00
David Capello
ce6c85996e Update laf library (base/path is gone, use base/fs) 2016-11-01 19:14:05 -03:00
David Capello
c60e0b915c Merge branch 'master' into beta 2016-10-27 13:00:57 -03:00
David Capello
cc18334c5a Changes in LOG/TRACE messages 2016-10-27 12:25:33 -03:00
David Capello
20b726f73b Merge branch 'master' into beta 2016-08-31 19:53:52 -03:00
David Capello
5ecc356a41 Replace GPL license with the new EULA 2016-08-29 13:08:21 -03:00
David Capello
be704d27f3 Don't list incompatible session in data recovery
An incompatible session is when the backup was done with another
Aseprite version number that the running instance.
2016-08-25 17:40:02 -03:00
David Capello
495a645917 Add possibility to recover raw images from a session (as a sequence of frames or layers)
This might be useful in extreme cases where the normal restoration
procedure doesn't work/restore the whole sprite structure correctly.
2016-04-07 16:12:03 -03:00
David Capello
cf8cd97cb6 Use new FSTREAM_PATH() macro to open fstreams 2015-05-20 15:34:36 -03:00
David Capello
f96293d1e8 Recover files with other filename to avoid confusion (related to #637) 2015-04-22 18:53:03 -03:00
David Capello
8e150dcbee We don't need a DocumentWriter lock to make the session backup 2015-04-21 11:06:46 -03:00
David Capello
ef522206f4 Avoid warning about unused var in release mode 2015-04-16 14:40:55 -03:00
David Capello
1bed018ab0 Add timeout parameter to Context/Document lock/unlock operations 2015-04-10 11:10:42 -03:00
David Capello
a6b4b295a6 Minor fixes in app::crash to compile on clang and gcc 2015-04-09 13:47:21 -03:00
David Capello
2ee6df8038 Save "ver" file in the session directory to know which Aseprite version was used 2015-04-09 08:10:09 -03:00
David Capello
77ec6c9e17 Save filename in "doc" file 2015-04-08 21:32:41 -03:00
David Capello
409d575948 Catch problems removing documents/directories 2015-04-08 20:46:00 -03:00
David Capello
a4478e9306 Add UI and logic to recover a backup session
Changes:
* Add DataRecoveryView
* Split SubObjectsIO into an interface and SubObjectsFromSprite
* Add a "setId" parameter to some doc::read_* functions (we need this
  functionality from session recovery)
2015-04-08 20:05:05 -03:00
David Capello
9ca4d15d74 Backup document data in a raw format directly on disk 2015-04-07 14:51:10 -03:00
David Capello
613e710ccf Support wchar_t* strings on Win32 to open std::ofstreams 2015-04-07 01:28:11 -03:00
David Capello
0bde95650d Save document backups in background session each 5 minutes 2015-04-06 12:06:50 -03:00
David Capello
f907cd0424 Remove unnecessary #include <windows.h> 2015-04-06 08:30:08 -03:00
David Capello
5c6860e7ac Change the way crash sessions are stored on disk
Changes:
* Move classes related to data recovery into app/crash/ directory/namespace
* Rename app::Backup to app::crash::Session
* Rename app::DataRecovery to app::crash::DataRecovery
* Add base::list_files()
* Add base::get_current_process_id() and base::is_process_running()
* Remove base::TempDir
* Save one session for each running process
* Remove sessions that are empty when the program starts
2015-04-05 18:51:43 -03:00