summaryrefslogtreecommitdiff
path: root/autosave.scm
diff options
context:
space:
mode:
authorAlessio Treglia <alessio@debian.org>2011-03-24 09:13:51 +0100
committerAlessio Treglia <alessio@debian.org>2011-03-24 09:13:51 +0100
commite5328e59987b90c4e98959510b810510e384650d (patch)
tree0f140b79d942c4654701d8fb4cfe2f1dd904f9f0 /autosave.scm
parent36cf8384e5699cda3f1ca607753fe4d4a8515b01 (diff)
Imported Upstream version 12.0
Diffstat (limited to 'autosave.scm')
-rw-r--r--autosave.scm14
1 files changed, 7 insertions, 7 deletions
diff --git a/autosave.scm b/autosave.scm
index 3457b2e..0a5ce12 100644
--- a/autosave.scm
+++ b/autosave.scm
@@ -42,8 +42,8 @@
temp-file)))
(do ((i 0 (+ 1 i)))
((= i (channels snd)))
- (if (hook-empty? (edit-hook snd i))
- (add-hook! (edit-hook snd i) (upon-edit snd))))
+ (if (null? (hook-functions (edit-hook snd i)))
+ (hook-push (edit-hook snd i) (upon-edit snd))))
(clear-unsaved-edits snd)))
(define (auto-save-done snd)
@@ -65,14 +65,14 @@
(sounds))
(in (* 1000 auto-save-interval) auto-save-func))))
- (if (not (member auto-save-done (hook->list close-hook)))
+ (if (not (member auto-save-done (hook-functions close-hook)))
(begin
(if (not (null? (sounds)))
(for-each auto-save-open-func (sounds)))
- (add-hook! after-open-hook auto-save-open-func)
- (add-hook! close-hook auto-save-done)
- (add-hook! save-hook (lambda (snd name) (auto-save-done snd)))
- (add-hook! exit-hook (lambda () (for-each auto-save-done (sounds))))))
+ (hook-push after-open-hook auto-save-open-func)
+ (hook-push close-hook auto-save-done)
+ (hook-push save-hook (lambda (snd name) (auto-save-done snd)))
+ (hook-push exit-hook (lambda () (for-each auto-save-done (sounds))))))
(set! auto-saving #t)
(in (* 1000 auto-save-interval) auto-save-func))