@@ -9,9 +9,9 @@ import PythonControlledNetPyNEStimulationSources from './redux/reduxconnect/NetP
99import NetPyNEStimulationTargets from './components/definition/stimulationTargets/NetPyNEStimulationTargets' ;
1010import NetPyNEPlots from './components/definition/plots/NetPyNEPlots' ;
1111import NetPyNESimConfig from './components/definition/configuration/NetPyNESimConfig' ;
12- import NetPyNEInstantiated from './components/instantiation/NetPyNEInstantiated' ;
1312import NetPyNEToolBar from './components/settings/NetPyNEToolBar' ;
1413import NetPyNETabs from './components/settings/NetPyNETabs' ;
14+ import LayoutManager from './redux/reduxconnect/LayoutManagerContainer' ;
1515
1616var PythonControlledCapability = require ( 'geppetto-client/js/communication/geppettoJupyter/PythonControlledCapability' ) ;
1717
@@ -30,7 +30,6 @@ export default class NetPyNE extends React.Component {
3030 this . state = {
3131 value : 'define' ,
3232 prevValue : 'define' ,
33- model : null ,
3433 tabClicked : false ,
3534 freezeInstance : false ,
3635 freezeSimulation : false ,
@@ -49,8 +48,6 @@ export default class NetPyNE extends React.Component {
4948 window . metadata = nextProps . data . metadata ;
5049 window . currentFolder = nextProps . data . currentFolder ;
5150 window . isDocker = nextProps . data . isDocker ;
52-
53- this . setState ( { model : nextProps . data } )
5451 }
5552 }
5653
@@ -136,7 +133,7 @@ export default class NetPyNE extends React.Component {
136133 }
137134
138135 render ( ) {
139- if ( this . state . model == null ) {
136+ if ( ! this . props . data ) {
140137 return < div > </ div >
141138 } else {
142139 if ( this . state . value == 'define' ) {
@@ -147,15 +144,15 @@ export default class NetPyNE extends React.Component {
147144 < PythonControlledNetPyNEConnectivity model = { "netParams.connParams" } />
148145 < PythonControlledNetPyNEStimulationSources model = { "netParams.stimSourceParams" } />
149146 < PythonControlledNetPyNEStimulationTargets model = { "netParams.stimTargetParams" } />
150- < NetPyNESimConfig model = { this . state . model . simConfig } />
147+ < NetPyNESimConfig model = { this . props . data . simConfig } />
151148 < PythonControlledNetPyNEPlots model = { "simConfig.analysis" } />
152149 </ div >
153150 } else {
154- var content = < NetPyNEInstantiated key = { this . state . freezeInstance ? "FIXME" : "PLEASE" } ref = { "simulate" } model = { this . state . model } page = { "simulate" } />
151+ var content = < LayoutManager />
155152 }
156153
157154 return (
158- < div style = { { height : '100%' , width :'100%' } } >
155+ < div style = { { height : '100%' , width :'100%' , display : 'flex' , flexDirection : 'column' } } >
159156 < div style = { { position : 'relative' , zIndex : '100' } } >
160157 < Toolbar id = "appBar" style = { { backgroundColor : '#543a73' , width :'100%' , boxShadow : '0 0px 4px 0 rgba(0, 0, 0, 0.2), 0 0px 8px 0 rgba(0, 0, 0, 0.19)' , position : 'relative' , top : '0px' , left : '0px' , zIndex : 100 } } >
161158 < div style = { { marginLeft : - 12 } } >
@@ -180,7 +177,7 @@ export default class NetPyNE extends React.Component {
180177 fastForwardInstantiation = { this . state . fastForwardInstantiation }
181178 fastForwardSimulation = { this . state . fastForwardSimulation }
182179 />
183-
180+
184181 { content }
185182 </ div >
186183 )
0 commit comments