Skip to content
Permalink
Browse files

Fixing drawing order of Extra Layers

  • Loading branch information
uprel committed Nov 24, 2019
1 parent 0357283 commit 30018f961cda8a9cc789eb532b8a45ee188ede05
Showing with 14 additions and 3 deletions.
  1. +4 −1 client/site/js/WebgisInit_functions.js
  2. +9 −1 client_common/eqwc_common.js
  3. +1 −1 client_mobile/src/map.js
@@ -580,14 +580,17 @@ function postLoading() {
//we need to make sure that OpenLayers.map.fallThrough is set to true
//otherwise the mouse events are swallowed
MapOptions.fallThrough = true;

var reverseExtra = Eqwc.common.reverseArray(extraLayers);

//creating the GeoExt map panel
geoExtMap = new GeoExt.MapPanel({
frame: false,
border: false,
//zoom: 1.6,
extent: projectData.makeExtentFromArray(projectData.extent.split(','), false),
layers: baseLayers.concat(
extraLayers.concat(
reverseExtra.concat(
[
thematicLayer = new OpenLayers.Layer.WMS(layerTree.root.firstChild.text,
wmsURI, {
@@ -201,4 +201,12 @@ Eqwc.common.parseInputTextToCoord = function(input) {
}

return coord;
};
};

Eqwc.common.reverseArray = function(arr) {
var newArray = [];
for (var i = arr.length - 1; i >= 0; i--) {
newArray.push(arr[i]);
}
return newArray;
}
@@ -415,7 +415,7 @@ Map.setBackgroundLayer = function (layerName, layerId, isBase) {
layOl3.name = lay.name;

// add background as base layer
Map.map.getLayers().insertAt(layerId, layOl3);
Map.map.getLayers().insertAt(0, layOl3);
Map.backgroundLayers[layOl3.name] = layOl3;
};

0 comments on commit 30018f9

Please sign in to comment.
You can’t perform that action at this time.