[Chameleon] MapObject's extent after zoomIn

Paul Spencer pagameba at magma.ca
Fri Oct 8 14:23:06 EDT 2004


Hi,

the issue is *when* the various widgets are processed.  Every widget has 
a priority.  It would appear that the change in extents does not happen 
until after the WMSBrowser widget ParseURL is called.  Note that in 
InitDefaults you will always get the previous extents.

One way to work around this is to get the extents in DrawPublish or any 
of the GetXXXXX functions ... these are all called after every widget 
has completed a ParseURL.  Since ParseURL is the only place widgets are 
supposed to make changes to the map, this would mean that you would get 
the updated extents in DrawPublish (or GetJavascriptFunctions ... which 
is where I think you might need it in this case).

Cheers,

Paul

Naijun Zhou wrote:
> Hi,
> 
> I tried to allow WMSBrowser.widget.php to obtain the mapobject's extent 
> (minx,miny,maxx,maxy) every time after the zoomIn (map_navigator.php). 
> For example, I can get the map's new extent in the map_navigator.php 
> after the zoomrectangle:
>        $oMap->zoomrectangle($oPixelRect, $oMap->width, $oMap->height, 
> $oCurrentExt);
> 
> However, it seems the map extent in WMSBrowser is delayed after the 
> map_navigator.php. That is, in both functions of InitDefaults() and 
> ParseURL(), when the map extent is obtained, the extent is acutally the 
> previous zoomed extent.
> 
> Is there a way that I can get the extent from the WMSBrowser?
> 
> Thank you very much!
> 
> N.Zhou
> 
>>
> 
> _________________________________________________________________
> Is your PC infected? Get a FREE online computer virus scan from McAfee® 
> Security. http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963
> 
> _______________________________________________
> Chameleon mailing list
> Chameleon at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/chameleon
> 

-- 
  -----------------------------------------------------------------
|Paul Spencer                           pspencer at dmsolutions.ca   |
|-----------------------------------------------------------------|
|Applications & Software Development                              |
|DM Solutions Group Inc                 http://www.dmsolutions.ca/|
  -----------------------------------------------------------------



More information about the Chameleon mailing list