<br><font size=2 face="sans-serif">Thanks Alexandre,</font>
<br><font size=2 face="sans-serif">More detailed... </font>
<br><font size=2 face="sans-serif">Per example, a user could watch the
whole world and the ov-map will be zoomed on Chicoutimi. Whatever the user
do on the main map (panning, zooming), I want the ov-map to stick on Chicoutimi,
because it is so beautiful ;-)</font>
<br><font size=2 face="sans-serif">But if a layer is selected on the tree
I want both maps to show it.</font>
<br><font size=2 face="sans-serif">So if I understood well your idea I
don't need to add a mapmove event since the ov-map will have a fix position.</font>
<br><font size=2 face="sans-serif">But, cloning layers and add handler
function on each node will do what I expect.</font>
<br>
<br><font size=2 face="sans-serif">Of course, I need to anchor this new
map in the bottom right corner.</font>
<br><font size=2 face="sans-serif">Correct me if I'm wrong</font>
<br><font size=2 face="sans-serif">thanks again</font>
<br><font size=2 face="sans-serif">Steve</font>
<br>
<br><font size=2 face="sans-serif"><br>
</font>
<br>
<br>
<br>
<table width=100%>
<tr valign=top>
<td width=40%><font size=1 face="sans-serif"><b>Alexandre Dube &lt;adube@mapgears.com&gt;</b>
</font>
<p><font size=1 face="sans-serif">04/02/2010 03:36 PM</font>
<td width=59%>
<table width=100%>
<tr valign=top>
<td>
<div align=right><font size=1 face="sans-serif">A</font></div>
<td><font size=1 face="sans-serif">Steve.Toutant@inspq.qc.ca</font>
<tr valign=top>
<td>
<div align=right><font size=1 face="sans-serif">cc</font></div>
<td><font size=1 face="sans-serif">users@openlayers.org</font>
<tr valign=top>
<td>
<div align=right><font size=1 face="sans-serif">Objet</font></div>
<td><font size=1 face="sans-serif">Re: [OpenLayers-Users] Magnifier window</font></table>
<br>
<table>
<tr valign=top>
<td>
<td></table>
<br></table>
<br>
<br>
<br>
<br>
<br><tt><font size=2>Hi Steve,<br>
<br>
 &nbsp;I think you could do something like that (pseudo-code) :<br>
<br>
 &nbsp;Create your original map<br>
 &nbsp;Create all your layers and add them to the map<br>
<br>
 &nbsp;Create your ov-map<br>
 &nbsp;Register a mapmove event to the map to make ov-map follow it<br>
 &nbsp;For each layer<br>
 &nbsp; &nbsp;Clone it and add it to ov-map<br>
 &nbsp; &nbsp;Register a visibilitychange event to a onVisibilityChanged
function<br>
<br>
 &nbsp;onVisibilityChanged: function(event)<br>
 &nbsp; &nbsp;var layers = ov-map.getLayersByName(this.name); // this is
the layer <br>
the visibility was changed<br>
 &nbsp; &nbsp;if(layers &amp;&amp; layers.length == 1)<br>
 &nbsp; &nbsp; &nbsp;layers[0].setVisibility(this.visibility())<br>
<br>
Do you get the idea ?<br>
<br>
Best regards,<br>
<br>
Alexandre<br>
<br>
Steve.Toutant@inspq.qc.ca wrote:<br>
&gt;<br>
&gt; Hi,<br>
&gt; I'm using openlayers with geoext.<br>
&gt; I would like to create a magnifier window. So it is like an overview
<br>
&gt; map with a fix map center and a fix zoom level, but the main map and
<br>
&gt; this overview map share the same geoext tree, so the layers are <br>
&gt; shown/hidden on both maps.<br>
&gt;<br>
&gt; I think I can do it if I start with the overview map example, here<br>
&gt; http://www.openlayers.org/dev/examples/example-list.html<br>
&gt;<br>
&gt; Does someone have a better idea or already tried this?<br>
&gt;<br>
&gt; thanks in advance<br>
&gt; Steve<br>
&gt;<br>
&gt; ------------------------------------------------------------------------<br>
&gt;<br>
&gt; _______________________________________________<br>
&gt; Users mailing list<br>
&gt; Users@openlayers.org<br>
&gt; http://openlayers.org/mailman/listinfo/users<br>
&gt; &nbsp; <br>
<br>
<br>
-- <br>
Alexandre Dubé<br>
Mapgears<br>
www.mapgears.com<br>
<br>
</font></tt>
<br>
<br>
<br>