mirror of
https://github.com/TomHarte/CLK.git
synced 2025-02-04 14:30:19 +00:00
Added precaution to make sure best-effort updaters aren't mid-update during document destruction.
This commit is contained in:
parent
61ad0f8bdc
commit
b274d7008c
@ -92,6 +92,7 @@ class MachineDocument:
|
||||
}
|
||||
|
||||
override func close() {
|
||||
bestEffortUpdater.flush()
|
||||
actionLock.lock()
|
||||
drawLock.lock()
|
||||
openGLView.invalidate()
|
||||
|
@ -25,5 +25,6 @@
|
||||
@property (nonatomic, weak) id<CSBestEffortUpdaterDelegate> delegate;
|
||||
|
||||
- (void)update;
|
||||
- (void)flush;
|
||||
|
||||
@end
|
||||
|
@ -63,4 +63,9 @@
|
||||
}
|
||||
}
|
||||
|
||||
- (void)flush
|
||||
{
|
||||
dispatch_sync(_serialDispatchQueue, ^{});
|
||||
}
|
||||
|
||||
@end
|
||||
|
Loading…
x
Reference in New Issue
Block a user