New OpenLayers.CANVAS_SUPPORTED constant

This commit is contained in:
fredj
2012-01-18 14:03:25 +01:00
parent 2c0b13957e
commit 14624cb815
2 changed files with 10 additions and 2 deletions

View File

@@ -110,8 +110,7 @@ OpenLayers.Renderer.Canvas = OpenLayers.Class(OpenLayers.Renderer, {
* {Boolean} Whether or not the browser supports the renderer class
*/
supported: function() {
var canvas = document.createElement("canvas");
return !!canvas.getContext;
return OpenLayers.CANVAS_SUPPORTED;
},
/**