attempt to properly redraw when gmaps change size
@@ -110,8 +110,13 @@ export class GMapPlotCanvasView extends PlotCanvasView
# create the map with above options in div
@map = new maps.Map(@canvas_view.map_el, map_options)
- # update bokeh ranges whenever the map idles, which should be after any UI action
- maps.event.addListenerOnce(@map, 'idle', @_set_bokeh_ranges)
+ # update bokeh ranges whenever the map idles, which should be after most UI action
+ maps.event.addListener(@map, 'idle',
+ @_set_bokeh_ranges
+ @render())
+
+ # also need an event when bounds change so that map resizes trigger renders too
+ maps.event.addListener(@map, 'bounds_changed', () => @_set_bokeh_ranges())
# wire up listeners so that changes to properties are reflected
@connect(@model.plot.properties.map_options.change, () => @_update_options())
