Use the last child of the container only if loading was aborted
Otherwise we may pick a tile that is already half way through the transition, which will cause the backbuffer to go away too early.
This commit is contained in:
@@ -1116,7 +1116,8 @@ OpenLayers.Layer.Grid = OpenLayers.Class(OpenLayers.Layer.HTTPRequest, {
|
|||||||
this.removeBackBuffer();
|
this.removeBackBuffer();
|
||||||
} else {
|
} else {
|
||||||
// wait until transition has ended or delay has passed
|
// wait until transition has ended or delay has passed
|
||||||
this._transitionElement = this.div.lastChild;
|
this._transitionElement = aborted ?
|
||||||
|
this.div.lastChild : tile.imgDiv;
|
||||||
var transitionendEvents = this.transitionendEvents;
|
var transitionendEvents = this.transitionendEvents;
|
||||||
for (var i=transitionendEvents.length-1; i>=0; --i) {
|
for (var i=transitionendEvents.length-1; i>=0; --i) {
|
||||||
OpenLayers.Event.observe(this._transitionElement,
|
OpenLayers.Event.observe(this._transitionElement,
|
||||||
|
|||||||
Reference in New Issue
Block a user