Merge pull request #1113 from tschaub/point-symbolizers
ol.style.Shape and ol.style.Icon don't inherit from ol.style.Point.
This commit is contained in:
@@ -17,6 +17,7 @@ goog.require('ol.style.Point');
|
||||
* @param {ol.style.IconOptions} options Icon options.
|
||||
*/
|
||||
ol.style.Icon = function(options) {
|
||||
goog.base(this);
|
||||
|
||||
goog.asserts.assert(options.url, 'url must be set');
|
||||
|
||||
@@ -91,6 +92,7 @@ ol.style.Icon = function(options) {
|
||||
options.zIndex : new ol.expr.Literal(options.zIndex);
|
||||
|
||||
};
|
||||
goog.inherits(ol.style.Icon, ol.style.Point);
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -20,6 +20,7 @@ goog.require('ol.style.Stroke');
|
||||
* @param {ol.style.ShapeOptions} options Shape options.
|
||||
*/
|
||||
ol.style.Shape = function(options) {
|
||||
goog.base(this);
|
||||
|
||||
/**
|
||||
* @type {ol.style.ShapeType}
|
||||
@@ -63,6 +64,7 @@ ol.style.Shape = function(options) {
|
||||
options.zIndex : new ol.expr.Literal(options.zIndex);
|
||||
|
||||
};
|
||||
goog.inherits(ol.style.Shape, ol.style.Point);
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -15,6 +15,7 @@ describe('ol.style.Icon', function() {
|
||||
yOffset: 15
|
||||
});
|
||||
expect(symbolizer).to.be.a(ol.style.Icon);
|
||||
expect(symbolizer).to.be.a(ol.style.Point);
|
||||
});
|
||||
|
||||
it('accepts expressions', function() {
|
||||
@@ -527,3 +528,4 @@ goog.require('ol.geom.GeometryType');
|
||||
goog.require('ol.geom.Point');
|
||||
goog.require('ol.style.Icon');
|
||||
goog.require('ol.style.IconLiteral');
|
||||
goog.require('ol.style.Point');
|
||||
|
||||
@@ -12,6 +12,7 @@ describe('ol.style.Shape', function() {
|
||||
})
|
||||
});
|
||||
expect(symbolizer).to.be.a(ol.style.Shape);
|
||||
expect(symbolizer).to.be.a(ol.style.Point);
|
||||
});
|
||||
|
||||
it('accepts expressions', function() {
|
||||
@@ -329,6 +330,7 @@ goog.require('ol.geom.GeometryType');
|
||||
goog.require('ol.geom.Point');
|
||||
goog.require('ol.expr');
|
||||
goog.require('ol.style.Fill');
|
||||
goog.require('ol.style.Point');
|
||||
goog.require('ol.style.Shape');
|
||||
goog.require('ol.style.ShapeLiteral');
|
||||
goog.require('ol.style.ShapeType');
|
||||
|
||||
Reference in New Issue
Block a user