diff --git a/src/widget/widgets/topology.js b/src/widget/widgets/topology.js index b5def70..784cf76 100644 --- a/src/widget/widgets/topology.js +++ b/src/widget/widgets/topology.js @@ -16,7 +16,7 @@ ******************************************************************************/ import React from 'react'; -import {UncontrolledReactSVGPanZoom} from 'react-svg-pan-zoom'; +import {INITIAL_VALUE, ReactSVGPanZoom, TOOL_NONE} from 'react-svg-pan-zoom'; import '../../styles/simple-spinner.css'; import { cimsvg } from 'libcimsvg'; import AppDispatcher from "../../common/app-dispatcher"; @@ -86,7 +86,9 @@ class WidgetTopology extends React.Component { this.state = { - file: file + file: file, + tool: TOOL_NONE, + value: INITIAL_VALUE, }; } @@ -169,7 +171,17 @@ class WidgetTopology extends React.Component { } + changeTool(nextTool) { + this.setState({tool: nextTool}) + } + + changeValue(nextValue) { + this.setState({value: nextValue}) + } + render() { + + console.log("Topology widget: ", this.props.widget); var markup = null; const miniatureProps = { miniaturePosition: "none", @@ -186,14 +198,15 @@ class WidgetTopology extends React.Component { markup =