Plays/pauses the player.
()
| 97 | |
| 98 | /** Plays/pauses the player. */ |
| 99 | playOrPause() { |
| 100 | if (this.isPlaying) { |
| 101 | this.isPlaying = false; |
| 102 | this.pause(); |
| 103 | } else { |
| 104 | this.isPlaying = true; |
| 105 | if (iter === 0) { |
| 106 | simulationStarted(); |
| 107 | } |
| 108 | this.play(); |
| 109 | } |
| 110 | } |
| 111 | |
| 112 | onPlayPause(callback: (isPlaying: boolean) => void) { |
| 113 | this.callback = callback; |
no test coverage detected