mirror of
https://github.com/TomHarte/CLK.git
synced 2024-11-26 23:52:26 +00:00
Switched time of best-effort updater delegate setting, to avoid a callback before setupClockRate has happened, and therefore before it's clear what should be going on with audio.
This commit is contained in:
parent
997707a45b
commit
dcd0c90283
@ -56,7 +56,6 @@ class MachineDocument:
|
|||||||
|
|
||||||
self.machine.delegate = self
|
self.machine.delegate = self
|
||||||
self.bestEffortUpdater = CSBestEffortUpdater()
|
self.bestEffortUpdater = CSBestEffortUpdater()
|
||||||
self.bestEffortUpdater.delegate = self
|
|
||||||
|
|
||||||
// callbacks from the OpenGL may come on a different thread, immediately following the .delegate set;
|
// callbacks from the OpenGL may come on a different thread, immediately following the .delegate set;
|
||||||
// hence the full setup of the best-effort updater prior to setting self as a delegate
|
// hence the full setup of the best-effort updater prior to setting self as a delegate
|
||||||
@ -68,6 +67,9 @@ class MachineDocument:
|
|||||||
|
|
||||||
// bring OpenGL view-holding window on top of the options panel
|
// bring OpenGL view-holding window on top of the options panel
|
||||||
self.openGLView.window!.makeKeyAndOrderFront(self)
|
self.openGLView.window!.makeKeyAndOrderFront(self)
|
||||||
|
|
||||||
|
// start accepting best effort updates
|
||||||
|
self.bestEffortUpdater.delegate = self
|
||||||
}
|
}
|
||||||
|
|
||||||
func machineDidChangeClockRate(_ machine: CSMachine!) {
|
func machineDidChangeClockRate(_ machine: CSMachine!) {
|
||||||
|
Loading…
Reference in New Issue
Block a user