File tree Expand file tree Collapse file tree 3 files changed +28
-24
lines changed
services/static-webserver/client/source/class/osparc Expand file tree Collapse file tree 3 files changed +28
-24
lines changed Original file line number Diff line number Diff line change @@ -752,13 +752,15 @@ qx.Class.define("osparc.desktop.WorkbenchView", {
752752 __iFrameChanged : function ( node ) {
753753 this . __iframePage . removeAll ( ) ;
754754
755- const loadingPage = node . getLoadingPage ( ) ;
756- const iFrame = node . getIFrame ( ) ;
757- const src = iFrame . getSource ( ) ;
758- const iFrameView = ( src === null || src === "about:blank" ) ? loadingPage : iFrame ;
759- this . __iframePage . add ( iFrameView , {
760- flex : 1
761- } ) ;
755+ if ( node ) {
756+ const loadingPage = node . getLoadingPage ( ) ;
757+ const iFrame = node . getIFrame ( ) ;
758+ const src = iFrame . getSource ( ) ;
759+ const iFrameView = ( src === null || src === "about:blank" ) ? loadingPage : iFrame ;
760+ this . __iframePage . add ( iFrameView , {
761+ flex : 1
762+ } ) ;
763+ }
762764 } ,
763765
764766 __populateSecondaryColumn : function ( node ) {
Original file line number Diff line number Diff line change @@ -143,14 +143,15 @@ qx.Class.define("osparc.node.slideshow.NodeView", {
143143 this . _iFrameLayout . removeAll ( ) ;
144144
145145 const node = this . getNode ( ) ;
146-
147- const loadingPage = node . getLoadingPage ( ) ;
148- const iFrame = node . getIFrame ( ) ;
149- const src = iFrame . getSource ( ) ;
150- const iFrameView = ( src === null || src === "about:blank" ) ? loadingPage : iFrame ;
151- this . _iFrameLayout . add ( iFrameView , {
152- flex : 1
153- } ) ;
146+ if ( node ) {
147+ const loadingPage = node . getLoadingPage ( ) ;
148+ const iFrame = node . getIFrame ( ) ;
149+ const src = iFrame . getSource ( ) ;
150+ const iFrameView = ( src === null || src === "about:blank" ) ? loadingPage : iFrame ;
151+ this . _iFrameLayout . add ( iFrameView , {
152+ flex : 1
153+ } ) ;
154+ }
154155 }
155156 }
156157} ) ;
Original file line number Diff line number Diff line change @@ -93,15 +93,16 @@ qx.Class.define("osparc.viewer.NodeViewer", {
9393 __iFrameChanged : function ( ) {
9494 this . _removeAll ( ) ;
9595
96- const iframeHandler = this . getNode ( ) . getIframeHandler ( ) ;
97-
98- const loadingPage = iframeHandler . getLoadingPage ( ) ;
99- const iFrame = iframeHandler . getIFrame ( ) ;
100- const src = iFrame . getSource ( ) ;
101- const iFrameView = ( src === null || src === "about:blank" ) ? loadingPage : iFrame ;
102- this . _add ( iFrameView , {
103- flex : 1
104- } ) ;
96+ if ( this . getNode ( ) && this . getNode ( ) . getIframeHandler ( ) ) {
97+ const iframeHandler = this . getNode ( ) . getIframeHandler ( ) ;
98+ const loadingPage = iframeHandler . getLoadingPage ( ) ;
99+ const iFrame = iframeHandler . getIFrame ( ) ;
100+ const src = iFrame . getSource ( ) ;
101+ const iFrameView = ( src === null || src === "about:blank" ) ? loadingPage : iFrame ;
102+ this . _add ( iFrameView , {
103+ flex : 1
104+ } ) ;
105+ }
105106 } ,
106107
107108 __attachSocketEventHandlers : function ( ) {
You can’t perform that action at this time.
0 commit comments