/// <summary> /// Create a polyline using the passed PolylineOptions, which specify both the path of the polyline and the stroke style to use when drawing the polyline. /// </summary> public async static Task <Polyline> CreateAsync(IJSRuntime jsRuntime, PolylineOptions opts = null) { var jsObjectRef = await JsObjectRef.CreateAsync(jsRuntime, "google.maps.Polyline", opts); var obj = new Polyline(jsObjectRef, opts); return(obj); }
public Task SetOptions(PolylineOptions options) { return(_jsRuntime.InvokeWithDefinedGuidAndMethodAsync <bool>( "googleMapPolylineJsFunctions.invoke", _guid.ToString(), "setOptions", options)); }
/// <summary> /// Create a polyline using the passed PolylineOptions, which specify both the path of the polyline and the stroke style to use when drawing the polyline. /// </summary> public Polyline(IJSRuntime jsRuntime, PolylineOptions opts = null) : base(jsRuntime) { if (opts != null) { _map = opts.Map; _jsRuntime.InvokeWithDefinedGuidAsync <bool>( "googleMapPolylineJsFunctions.init", _guid.ToString(), opts); } else { _jsRuntime.InvokeWithDefinedGuidAsync <bool>( "googleMapPolylineJsFunctions.init", _guid.ToString()); } }
/// <summary> /// Create a polyline using the passed PolylineOptions, which specify both the path of the polyline and the stroke style to use when drawing the polyline. /// </summary> private Polyline(JsObjectRef jsObjectRef, PolylineOptions opts = null) { _jsObjectRef = jsObjectRef; _map = opts?.Map; }
public Task SetOptions(PolylineOptions options) { return(_jsObjectRef.InvokeAsync( "setOptions", options)); }