diff options
| author | hallgren <hallgren@chalmers.se> | 2011-10-12 17:03:54 +0000 |
|---|---|---|
| committer | hallgren <hallgren@chalmers.se> | 2011-10-12 17:03:54 +0000 |
| commit | 44d1a5a9f71b03d9aceeccd760a63fcdc45f8bad (patch) | |
| tree | d51076a708997d6f1af6ac0deefd535bbc25f804 /src/editor/simple/localstorage.js | |
| parent | 0aba45560d2033c37c3d2e876e6f3ef89e1554d6 (diff) | |
Improvements of "gf -server" mode and related setup
"gf -server" mode now contains everything needed to run the minibar and
the grammar editor (including example-based grammar writing).
The Setup.hs script installs the required files where gf -server can find them.
These files have been moved to a new directory: src/www.
The separate server program pgf-http is now obsolete.
Diffstat (limited to 'src/editor/simple/localstorage.js')
| -rw-r--r-- | src/editor/simple/localstorage.js | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/src/editor/simple/localstorage.js b/src/editor/simple/localstorage.js deleted file mode 100644 index 31201998c..000000000 --- a/src/editor/simple/localstorage.js +++ /dev/null @@ -1,21 +0,0 @@ - -// We use localStorage to store the grammars, -// see http://diveintohtml5.org/storage.html - -var local={ - prefix:"gf.editor.simple.grammar", - get: function (name,def) { - var id=this.prefix+name - return localStorage[id] ? JSON.parse(localStorage[id]) : def; - }, - put: function (name,value) { - var id=this.prefix+name; - localStorage[id]=JSON.stringify(value); - }, - remove: function(name) { - var id=this.prefix+name; - localStorage.removeItem(id); - }, - get count() { return this.get("count",0); }, - set count(v) { this.put("count",v); } -} |
