MCPcopy Create free account
hub / github.com/DHTMLX/scheduler / setUserLocation

Function setUserLocation

codebase/sources/dhtmlxscheduler.js:13901–13911  ·  view source on GitHub ↗
(options, adapter)

Source from the content-addressed store, hash-verified

13899 return event2;
13900 }
13901 function setUserLocation(options, adapter) {
13902 if (options.resolve_user_location) {
13903 if (navigator.geolocation) {
13904 navigator.geolocation.getCurrentPosition(function(position) {
13905 adapter.setView(position.coords.latitude, position.coords.longitude, options.zoom_after_resolve || options.initial_zoom);
13906 });
13907 }
13908 } else {
13909 adapter.setView(options.initial_position.lat, options.initial_position.lng, options.initial_zoom);
13910 }
13911 }
13912 scheduler2.dblclick_dhx_map_area = function(e) {
13913 let eventNode = e.target.closest(`[${scheduler2.config.event_attribute}]`);
13914 if (eventNode) {

Callers 1

map_viewFunction · 0.70

Calls 1

setViewMethod · 0.45

Tested by

no test coverage detected