My impression is that the map commands "go" when the rendering is not using the 
current Map data structure. Since the rendering process is threaded this is not 
quite the same thing as waiting for rendering to complete. 

The ZoomExtentCommand checks the current "Area of Interest", and there are 
several strategies which can configured to determine how this value is 
calculated. The default one goes through the layers, and checks the 
GeoResourceInfo object for each layer to determine the requested bounds. 

-- 
Jody Garnett


On Thursday, 26 July 2012 at 5:09 PM, Elvie DSouza wrote:

> Hi,
> 
> I have menu command which will close all the open views in my application. 
> When this happens, the map area increases and viewport is rendered.
> 
> Now, the problem is, that I have to explicitly click the 'Show All' action to 
> fit the map. I need it to happen programatically. I have tried executing 
> 'ZoomExtentCommand' but it doesn't give the desired result. I guess it 
> happens because the map is still being rendered when this command is executed.
> 
> Is there a way to either find the status of the renderer and wait for 
> rendering to get over or execute 'ZoomExtentCommand' after rendering is done?
> 
> Thanks
> Elvie
> 
> 
> _______________________________________________
> User-friendly Desktop Internet GIS (uDig)
> http://udig.refractions.net
> http://lists.refractions.net/mailman/listinfo/udig-devel
> 
> 


_______________________________________________
User-friendly Desktop Internet GIS (uDig)
http://udig.refractions.net
http://lists.refractions.net/mailman/listinfo/udig-devel

Reply via email to