SVoyt / esri-leaflet-dynamic-advanced

Other
9 stars 6 forks source link

DynamicMapLayer redraw function missing #8

Closed UsgsMonkey closed 6 years ago

UsgsMonkey commented 6 years ago

This may be a gap in my JavaScripting knowledge but I'm also not sure of your implementation. The original DynamicMapLayer has a 'redraw' function. If this class is an extension of that class, is that root class still exposed somewhere where I can get a hook to call 'redraw' or do you need to explicitly expose this function through your new API?

(I searched the prototype chain for the DynamicMapLayerAdvanced object in my implementation and was unable to locate any 'redraw' function)

Pretty-please restore the 'redraw' function into this implementation (if this is the recommended resolution)! While your class solves some key issues for us, if it lacks this functionality this just creates a whole new set of problems...

jgravois commented 6 years ago

the method you're looking for is _update().

in esri-leaflet, DynamicMapLayer.redraw() just calls _update() internally.

SVoyt commented 6 years ago

DynamicMapLayerAdvanced extends L.Layer, not DynamicMapLayer. So, you should use _update() function as @jgravois said.

UsgsMonkey commented 6 years ago

I think I hear angels singing. Thanks guys :)

UsgsMonkey commented 6 years ago

That did the trick. Thanks again!