From 744ee039bd12f19f13f4aa1d99ee3055afa9abb7 Mon Sep 17 00:00:00 2001 From: bartvde Date: Fri, 4 Jun 2010 19:24:10 +0000 Subject: [PATCH] Deprecate the theme map option, p=ahocevar, r=me (closes #2619) git-svn-id: http://svn.openlayers.org/trunk/openlayers@10372 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf --- lib/OpenLayers/Map.js | 37 ++++------------------ tests/Map.html | 74 +++---------------------------------------- 2 files changed, 10 insertions(+), 101 deletions(-) diff --git a/lib/OpenLayers/Map.js b/lib/OpenLayers/Map.js index 7053050950..00a8b9f5a2 100644 --- a/lib/OpenLayers/Map.js +++ b/lib/OpenLayers/Map.js @@ -355,12 +355,13 @@ OpenLayers.Map = OpenLayers.Class({ /** * APIProperty: theme - * {String} Relative path to a CSS file from which to load theme styles. - * Specify null in the map options (e.g. {theme: null}) if you - * want to get cascading style declarations - by putting links to - * stylesheets or style declarations directly in your page. + * {String} *Deprecated* Relative path to a CSS file from which to load + * theme styles. Add a CSS resource in the HTML of your map page + * instead, e.g.: + * (code) + * + * (end) */ - theme: null, /** * APIProperty: displayProjection @@ -480,9 +481,6 @@ OpenLayers.Map = OpenLayers.Class({ this.paddingForPopups = new OpenLayers.Bounds(15, 15, 15, 15); - this.theme = OpenLayers._getScriptLocation() + - 'theme/default/style.css'; - // now override default options OpenLayers.Util.extend(this, options); @@ -545,29 +543,6 @@ OpenLayers.Map = OpenLayers.Class({ this.updateSizeDestroy); } - // only append link stylesheet if the theme property is set - if(this.theme) { - // check existing links for equivalent url - var addNode = true; - var nodes = document.getElementsByTagName('link'); - for(var i=0, len=nodes.length; i