From 768bcd4d760318973485e517b775b884e69e0d8f Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Sat, 1 Sep 2012 02:39:10 +0400 Subject: [PATCH] added save state on unload... Signed-off-by: Alex A. Naanou --- ui/TODO.otl | 11 +++++++---- ui/gallery-prototype.js | 1 + 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/ui/TODO.otl b/ui/TODO.otl index ca715482..8e971c9a 100755 --- a/ui/TODO.otl +++ b/ui/TODO.otl @@ -1,16 +1,19 @@ Priority work - [_] 68% Preview II - [_] 53% save state + [_] 62% Preview II + [_] make shuft up/down direction-aware... + | i.e. if we are going through images in a direction select the + | next image in that direction when shifting... + [_] 57% save state [X] minimal: Local Storage (manual) | works across all targets (CEF, PhoneGap, browser) [_] local JSON (file) [_] CouchDB - [_] 75% autosave + [X] 100% autosave [X] on edit [X] on navigate | only save position to save time... [X] on timer - [_] on unload + [X] on unload [X] manual incremental save [_] manual named save [X] versions/history diff --git a/ui/gallery-prototype.js b/ui/gallery-prototype.js index 6ad7b3ad..6054dab5 100755 --- a/ui/gallery-prototype.js +++ b/ui/gallery-prototype.js @@ -1025,6 +1025,7 @@ function setDefaultInitialState(){ function setupEvents(){ var updated = false // persistence... + $(window).unload(ImageGrid.saveState) $(document) // main modifier events... .bind('shiftImageUp shiftImageDown reverseImageOrder '+