1

I'm using OpenLayers - 2.11,GeoServer 2.13, ExtJS 3.4, and Java for developing GIS based web applications. Please guide me to check if all my GeoServer map layers/tiles Loaded in the screen or not. While dragging map is taking time to load next tiles. So that time i want to mask all the map body and unmask after loading all the map tiles.

enter image description here

  • Are you debugging using Firebug? The Net tab and the Script Tab are most used for debugging these kinds of apps. – Devdatta Tengshe Oct 11 '13 at 7:17
  • Dear Devdatta Tengshe,thank you for your response. i'm using Firebug here.But, how we can find out that through coding? – Ramesh T R Oct 11 '13 at 7:19
2

You can listen to the Layer's loadend event like this:

layer.events.register("loadend", layer, function (e) {
                //<<---Do your process here
            });
| improve this answer | |
  • Dear Devdatta Tengshe..thank you.. i'm using different layer groups/layers in my map.Is there any method to check for all the layers? or All map area is loaded or not? – Ramesh T R Oct 11 '13 at 9:05
  • 1
    @RamRamesh: There is no event that fires when all layers are loaded. You need to listen to individual layer load events and then use somw custom logic to figure out if all layers are loaded. – Devdatta Tengshe Oct 11 '13 at 9:12
  • openlayers.org/dev/examples/layerLoadMonitoring.html example.. – Ramesh T R Oct 11 '13 at 10:29
0

openlayers.org/dev/examples/layerLoadMonitoring.html Example for Openlayers map layer events..

| improve this answer | |
  • The URL gets a blank page!!! – Taber Oct 11 '13 at 12:06
  • opening here..just click on that blue link. and check the source code – Ramesh T R Oct 11 '13 at 15:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.