From c2fc36f2e72340ab132a00de8d79a14211628cf4 Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Mon, 21 May 2018 20:08:51 +0200 Subject: statuses --- app/client/live/index.js | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'app/client/live/index.js') diff --git a/app/client/live/index.js b/app/client/live/index.js index fb512a3..4fc1b5c 100644 --- a/app/client/live/index.js +++ b/app/client/live/index.js @@ -6,6 +6,7 @@ import Player from './components/player.component' import ParamGroup from '../common/paramGroup.component' import Slider from '../common/slider.component' import Select from '../common/select.component' +import Button from '../common/button.component' import * as liveActions from './actions' @@ -19,6 +20,7 @@ class App extends Component { this.changeEpoch = this.changeEpoch.bind(this) this.changeSequence = this.changeSequence.bind(this) this.seek = this.seek.bind(this) + this.toggle = this.toggle.bind(this) } componentWillUpdate(nextProps) { if (nextProps.opt.checkpoint_name && nextProps.opt.checkpoint_name !== this.props.opt.checkpoint_name) { @@ -39,6 +41,13 @@ class App extends Component { const frame = Math.floor(percentage * (parseInt(this.props.frame.sequence_len) || 1) + 1) this.props.actions.seek(frame) } + toggle(){ + if (this.props.opt.processing) { + this.props.actions.pause() + } else { + this.props.actions.play() + } + } render(){ return (
@@ -78,6 +87,12 @@ class App extends Component { value={(this.props.frame.sequence_i || 0) / (this.props.frame.sequence_len || 1)} onChange={this.seek} /> +
+ Processing: {this.props.opt.processing} +
+
-- cgit v1.2.3-70-g09d2