File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed
Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -268,6 +268,16 @@ proto.updateFx = function(options) {
268268 fullLayout . hovermode = options . hovermode ;
269269} ;
270270
271+ var relayoutCallback = function ( scene ) {
272+ var update = { } ;
273+ update [ scene . id ] = { // scene.camera has no many useful projection or scale information
274+ lastInputTime : scene . camera . lastInputTime , // helps determine which one is the latest input (if async)
275+ xrange : scene . xaxis . range . slice ( 0 ) ,
276+ yrange : scene . yaxis . range . slice ( 0 )
277+ } ;
278+ scene . container . parentElement . parentElement . parentElement . emit ( 'plotly_relayout' , update ) ;
279+ } ;
280+
271281proto . cameraChanged = function ( ) {
272282 var camera = this . camera ,
273283 xrange = this . xaxis . range ,
@@ -285,6 +295,7 @@ proto.cameraChanged = function() {
285295 this . glplotOptions . ticks = nextTicks ;
286296 this . glplotOptions . dataBox = camera . dataBox ;
287297 this . glplot . update ( this . glplotOptions ) ;
298+ relayoutCallback ( this ) ;
288299 }
289300} ;
290301
You can’t perform that action at this time.
0 commit comments