<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
</head>
<body bgcolor="#ffffff" text="#000000">
<div class="moz-text-flowed" style="font-family: -moz-fixed;
font-size: 12px;" lang="x-western">Hi Philip,
<br>
<br>
You should create a ticket to be sure the commiters see the fix,
review it and add it in the future 2.11 release.
<br>
<br>
Thanks for the fix, it works for me.
<br>
<br>
Here some infos :
<br>
<br>
<a class="moz-txt-link-freetext"
href="http://trac.osgeo.org/openlayers/wiki/HowToContribute">http://trac.osgeo.org/openlayers/wiki/HowToContribute</a>
<br>
<a class="moz-txt-link-freetext"
href="http://trac.osgeo.org/openlayers/wiki/FilingTickets">http://trac.osgeo.org/openlayers/wiki/FilingTickets</a>
<br>
<a class="moz-txt-link-freetext"
href="http://trac.osgeo.org/openlayers/wiki/CreatingPatches">http://trac.osgeo.org/openlayers/wiki/CreatingPatches</a>
<br>
<br>
<br>
On 11/07/2011 21:39, Philip Collins wrote:
<br>
<blockquote type="cite" style="color: rgb(0, 0, 0);">Go to:
<br>
<a class="moz-txt-link-freetext"
href="http://openlayers.org/dev/examples/google-v3.html">http://openlayers.org/dev/examples/google-v3.html</a>
<br>
<br>
and make your browser window really skinny. Then try to switch
the base
<br>
layer. Nothing happens. Then try to make your browser a normal
size and
<br>
switch layers. Still nothing happens.
<br>
<br>
The problem is that the current code is relying upon google
sending a
<br>
tiles loaded event that never occurs. Here's some code to fix
that.
<br>
<br>
// patch openlayers 2.11RC to fix problem when switching to a
google layer
<br>
from a non google layer after resizing the map
<br>
OpenLayers.Layer.Google.v3.onMapResize = function() {
<br>
var cache = OpenLayers.Layer.Google.cache[this.map.id];
<br>
cache.resized = true;
<br>
};
<br>
OpenLayers.Layer.Google.v3.setGMapVisibility_old =
<br>
OpenLayers.Layer.Google.v3.setGMapVisibility;
<br>
OpenLayers.Layer.Google.v3.setGMapVisibility = function(visible)
{
<br>
var cache = OpenLayers.Layer.Google.cache[this.map.id];
<br>
if (visible&& cache&& cache.resized) {
<br>
google.maps.event.trigger(this.mapObject, "resize");
<br>
delete cache.resized;
<br>
}
<br>
OpenLayers.Layer.Google.v3.setGMapVisibility_old.apply(this,arguments);
<br>
};
<br>
<br>
Phil
<br>
<br>
</blockquote>
<br>
</div>
</body>
</html>