MCPcopy
hub / github.com/django/django / defaultCenter

Method defaultCenter

django/contrib/gis/static/gis/js/OLMapWidget.js:202–212  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

200 }
201
202 defaultCenter() {
203 const center = [this.options.default_lon, this.options.default_lat];
204 if (this.options.map_srid) {
205 return ol.proj.transform(
206 center,
207 "EPSG:4326",
208 this.map.getView().getProjection(),
209 );
210 }
211 return center;
212 }
213
214 enableDrawing() {
215 this.interactions.draw.setActive(true);

Callers 2

constructorMethod · 0.95
mapwidget.test.jsFile · 0.80

Calls 1

transformMethod · 0.45

Tested by

no test coverage detected