1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2025-11-13 05:47:17 +00:00

Add support for autosave

Causes the wiki to be autosaved whenever clicking “done” after editing
a tiddler. Only works with savers that support autosave. We should
probably make autosave configurable
This commit is contained in:
Jermolene
2014-02-04 21:21:01 +00:00
parent 4882f70557
commit 1d685df928
12 changed files with 44 additions and 55 deletions

View File

@@ -16,10 +16,6 @@ var TWEditSaver = function(wiki) {
};
TWEditSaver.prototype.save = function(text,method,callback) {
// Bail out unless this is a save (rather than a download)
if(method !== "save") {
return false;
}
// Bail if we're not running under TWEdit
if(typeof DeviceInfo !== "object") {
return false;
@@ -68,7 +64,8 @@ Information about this saver
*/
TWEditSaver.prototype.info = {
name: "twedit",
priority: 1600
priority: 1600,
capabilities: ["save", "autosave"]
};
/*