diff options
| author | Georgios Andreadis <g.andreadis@student.tudelft.nl> | 2017-11-03 15:28:39 +0100 |
|---|---|---|
| committer | Georgios Andreadis <g.andreadis@student.tudelft.nl> | 2017-11-03 15:28:39 +0100 |
| commit | f4fb3fae6366b380fe5f709ec3b6413dcafed4d5 (patch) | |
| tree | e9c3f947e76ddb63d51ea495a1c3d0ca95cfceab /src/reducers | |
| parent | e0a6e9550dd6c56c1eb97b3695c9e3e539f32a13 (diff) | |
Disable rack construction when leaving room
Diffstat (limited to 'src/reducers')
| -rw-r--r-- | src/reducers/construction-mode.js | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/src/reducers/construction-mode.js b/src/reducers/construction-mode.js index 4778bd44..c4c0c010 100644 --- a/src/reducers/construction-mode.js +++ b/src/reducers/construction-mode.js @@ -1,14 +1,12 @@ -import { combineReducers } from "redux"; -import { OPEN_EXPERIMENT_SUCCEEDED } from "../actions/experiments"; +import {combineReducers} from "redux"; +import {OPEN_EXPERIMENT_SUCCEEDED} from "../actions/experiments"; +import {GO_DOWN_ONE_INTERACTION_LEVEL} from "../actions/interaction-level"; import { CANCEL_NEW_ROOM_CONSTRUCTION_SUCCEEDED, FINISH_NEW_ROOM_CONSTRUCTION, START_NEW_ROOM_CONSTRUCTION_SUCCEEDED } from "../actions/topology/building"; -import { - START_RACK_CONSTRUCTION, - STOP_RACK_CONSTRUCTION -} from "../actions/topology/room"; +import {START_RACK_CONSTRUCTION, STOP_RACK_CONSTRUCTION} from "../actions/topology/room"; export function currentRoomInConstruction(state = -1, action) { switch (action.type) { @@ -29,6 +27,7 @@ export function inRackConstructionMode(state = false, action) { return true; case STOP_RACK_CONSTRUCTION: case OPEN_EXPERIMENT_SUCCEEDED: + case GO_DOWN_ONE_INTERACTION_LEVEL: return false; default: return state; |
