ordering <exclamation point/>. you can now gracefully z-order your vectors... and you can even 'yOrder' them and add background images, making for a nice 3dish look. be sure to check out the two new example html's: marker-shadow.html and ordering.html. Big thanks to tcoulter (funkyc) for a prolonged effort with this patch. It has come a long way and now what a beautiful finish. (Closes #1357)
git-svn-id: http://svn.openlayers.org/trunk/openlayers@7652 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -152,6 +152,13 @@ OpenLayers.Layer.Vector = OpenLayers.Class(OpenLayers.Layer, {
|
||||
* {<OpenLayers.Renderer>}
|
||||
*/
|
||||
renderer: null,
|
||||
|
||||
/**
|
||||
* APIProperty: yOrdering
|
||||
* {String} Whether or not externalGraphic y-ordering is enabled on this
|
||||
* layer. Default is false.
|
||||
*/
|
||||
yOrdering: false,
|
||||
|
||||
/**
|
||||
* APIProperty: geometryType
|
||||
@@ -252,8 +259,8 @@ OpenLayers.Layer.Vector = OpenLayers.Class(OpenLayers.Layer, {
|
||||
for (var i=0, len=this.renderers.length; i<this.renderers.length; i++) {
|
||||
var rendererClass = OpenLayers.Renderer[this.renderers[i]];
|
||||
if (rendererClass && rendererClass.prototype.supported()) {
|
||||
this.renderer = new rendererClass(this.div);
|
||||
break;
|
||||
this.renderer = new rendererClass(this.div, this.yOrdering);
|
||||
break;
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -332,7 +339,7 @@ OpenLayers.Layer.Vector = OpenLayers.Class(OpenLayers.Layer, {
|
||||
this.renderer.setExtent(extent);
|
||||
|
||||
this.renderer.root.style.visibility = "visible";
|
||||
|
||||
|
||||
// Force a reflow on gecko based browsers to prevent jump/flicker.
|
||||
// This seems to happen on only certain configurations; it was originally
|
||||
// noticed in FF 2.0 and Linux.
|
||||
|
||||
Reference in New Issue
Block a user