Revert "save to localstorage more frequently, fixes #1345"

This reverts commit 56413563c3.
This commit is contained in:
Ansis Brammanis
2013-05-02 11:54:14 -04:00
parent 56413563c3
commit b0abe207ed
-10
View File
@@ -114,16 +114,6 @@ iD.ui = function(context) {
.attr('tabindex', -1)
.call(iD.ui.Contributors(context));
// save changes to localstorage
history.on('change.localstorage', function() {
context.on('enter.localstorage', function(mode) {
if (mode.id === 'browse' || mode.id === 'select') {
context.on('enter.localstorage', null);
history.save();
}
});
});
window.onbeforeunload = function() {
history.save();
if (history.hasChanges()) return t('save.unsaved_changes');