MCPcopy Create free account
hub / github.com/codecombat/codecombat / onSliderInput

Method onSliderInput

app/views/admin/CodePlaybackView.js:165–174  ·  view source on GitHub ↗
(e)

Source from the content-addressed store, hash-verified

163 }
164
165 onSliderInput (e) {
166 this.clearPlayback()
167 this.$el.find('#start-time').text((((this.$el.find('#slider')[0].value / 100) * this.maxTime) / 1000).toFixed(0) + 's')
168 const render = this.spade.renderTime(this.options.events, this.ace, this.$el.find('#slider')[0].value / 100)
169 this.ace.setValue(render.result)
170 if ((render.selFIndex != null) && (render.selEIndex != null)) {
171 this.ace.selection.moveCursorToPosition(render.selFIndex)
172 return this.ace.selection.setSelectionAnchor(render.selEIndex.row, render.selEIndex.column)
173 }
174 }
175
176 clearPlayback () {
177 if (this.interval != null) { clearInterval(this.interval) }

Callers

nothing calls this directly

Calls 1

clearPlaybackMethod · 0.95

Tested by

no test coverage detected