From 80bba145d5bdbcddbb9b6baba25213aaffb6e781 Mon Sep 17 00:00:00 2001 From: MinRK Date: Tue, 16 Apr 2013 15:22:44 -0700 Subject: [PATCH] set default autosave interval to two minutes --- IPython/frontend/html/notebook/static/js/notebook.js | 3 ++- IPython/frontend/html/notebook/static/js/notebookmain.js | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/IPython/frontend/html/notebook/static/js/notebook.js b/IPython/frontend/html/notebook/static/js/notebook.js index fb9e9e05c..41d1b6e92 100644 --- a/IPython/frontend/html/notebook/static/js/notebook.js +++ b/IPython/frontend/html/notebook/static/js/notebook.js @@ -43,7 +43,8 @@ var IPython = (function (IPython) { this.last_checkpoint = null; this.autosave_interval = 0; this.autosave_timer = null; - this.minimum_autosave_interval = 30000; + // autosave *at most* every two minutes + this.minimum_autosave_interval = 120000; // single worksheet for now this.worksheet_metadata = {}; this.control_key_active = false; diff --git a/IPython/frontend/html/notebook/static/js/notebookmain.js b/IPython/frontend/html/notebook/static/js/notebookmain.js index 319f8cb4a..dc5e5f958 100644 --- a/IPython/frontend/html/notebook/static/js/notebookmain.js +++ b/IPython/frontend/html/notebook/static/js/notebookmain.js @@ -87,7 +87,7 @@ $(document).ready(function () { document.location.hash = ''; document.location.hash = hash; } - IPython.notebook.autosave_notebook(30000); + IPython.notebook.autosave_notebook(IPython.notebook.minimum_autosave_interval); // only do this once $([IPython.events]).off('notebook_loaded.Notebook', first_load); };