Forgot to invoke callback
parent
e4426eb01a
commit
5912cad83f
|
@ -12,9 +12,9 @@ T{ macosx-io } set-io-backend
|
|||
TUPLE: macosx-monitor ;
|
||||
|
||||
: enqueue-notifications ( triples monitor -- )
|
||||
monitor-queue [
|
||||
[ first { +modify-file+ } swap changed-file ] each
|
||||
] bind ;
|
||||
tuck monitor-queue
|
||||
[ [ first { +modify-file+ } swap changed-file ] each ] bind
|
||||
notify-callback ;
|
||||
|
||||
M: macosx-io <monitor>
|
||||
drop
|
||||
|
@ -25,4 +25,3 @@ M: macosx-io <monitor>
|
|||
|
||||
M: macosx-monitor dispose
|
||||
dup simple-monitor-handle dispose delegate dispose ;
|
||||
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
USING: threads io.files io.monitors init kernel tools.browser ;
|
||||
USING: threads io.files io.monitors init kernel tools.browser
|
||||
continuations ;
|
||||
IN: vocabs.monitor
|
||||
|
||||
! Use file system change monitoring to flush the tags/authors
|
||||
|
@ -7,8 +8,11 @@ IN: vocabs.monitor
|
|||
dup next-change 2drop reset-cache update-thread ;
|
||||
|
||||
: start-update-thread
|
||||
#! Silently ignore errors during monitor creation since
|
||||
#! monitors are not supported on all platforms.
|
||||
[
|
||||
"" resource-path t <monitor> update-thread
|
||||
[ "" resource-path t <monitor> ] [ drop f ] recover
|
||||
[ update-thread ] when*
|
||||
] in-thread ;
|
||||
|
||||
[ start-update-thread ] "tools.browser" add-init-hook
|
||||
|
|
Loading…
Reference in New Issue