diff options
Diffstat (limited to 'public/bundle.js')
| -rw-r--r-- | public/bundle.js | 69 |
1 files changed, 48 insertions, 21 deletions
diff --git a/public/bundle.js b/public/bundle.js index d7fe364..a6f6dd2 100644 --- a/public/bundle.js +++ b/public/bundle.js @@ -7764,6 +7764,46 @@ var System = function (_Component) { ), (0, _preact.h)( _group2.default, + { title: 'Tasks' }, + (0, _preact.h)( + _param2.default, + { title: 'Kill task' }, + (0, _preact.h)( + 'button', + { onClick: function onClick() { + return actions.queue.stop_task('cpu'); + } }, + 'CPU' + ), + (0, _preact.h)( + 'button', + { onClick: function onClick() { + return actions.queue.stop_task('gpu'); + } }, + 'GPU' + ) + ), + (0, _preact.h)( + _param2.default, + { title: 'Queue' }, + (0, _preact.h)( + 'button', + { onClick: function onClick() { + return actions.queue.start_queue(); + } }, + 'Start' + ), + (0, _preact.h)( + 'button', + { onClick: function onClick() { + return actions.queue.stop_queue(); + } }, + 'Stop' + ) + ) + ), + (0, _preact.h)( + _group2.default, { title: 'Test' }, (0, _preact.h)( _param2.default, @@ -7839,24 +7879,6 @@ var System = function (_Component) { ), (0, _preact.h)( _param2.default, - { title: 'Queue' }, - (0, _preact.h)( - 'button', - { onClick: function onClick() { - return actions.queue.start_queue(); - } }, - 'Start' - ), - (0, _preact.h)( - 'button', - { onClick: function onClick() { - return actions.queue.stop_queue(); - } }, - 'Stop' - ) - ), - (0, _preact.h)( - _param2.default, { title: '' }, (0, _preact.h)( 'button', @@ -8024,6 +8046,7 @@ var systemReducer = function systemReducer() { var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : systemInitialState; var action = arguments[1]; + var processor = null; switch (action.type) { case _types2.default.socket.connect: case _types2.default.socket.reconnecting: @@ -8137,8 +8160,12 @@ var systemReducer = function systemReducer() { stderr: "" }); case _types2.default.task.task_finish: - if (state.runner[action.task.processor].task.uuid !== action.task.uuid) { - return state; + if (state.runner.cpu.task.uuid === action.task.uuid) { + processor = 'cpu'; + } else if (state.runner.gpu.task.uuid === action.task.uuid) { + processor = 'gpu'; + } else { + processor = null; } return _extends({}, state, { rpc: { @@ -8146,7 +8173,7 @@ var systemReducer = function systemReducer() { status: "disconnected", error: null }, - runner: _extends({}, state.runner, _defineProperty({}, action.task.processor, { status: 'IDLE', task: {} })) + runner: processor ? _extends({}, state.runner, _defineProperty({}, processor, { status: 'IDLE', task: {} })) : state.runner }); case _types2.default.app.change_tool: return _extends({}, state, { |
