twpayne/ol3 — pull request #3 by twpayne (2013-01-23 20:20:45+00:00)
Title: Texture cache expiry

This PR adds a mechanism for the expiration of WebGL textures.

It's based similar techniques used by `ol.TileCache`, except with specific modifications to support the needs of the WebGL renderer.

It needs the function `goog.structs.LinkedMap.prototype.peekLastKey`, which sadly doesn't exist, and cannot be added by inheritance from `goog.structs.LinkedMap` because it requires access to private member variables. Therefore, `goog.structs.LinkedMap` has been copied into the code, renamed to `ol.structs.LinkedMap`, and the method has been added. `ol.TileCache` has been ported to `ol.structs.LinkedMap` to minimise build size. Meanwhile, a PR will be sent to the Closure Library to add the `peekLastKey` method.

Fixes #142.