Add offset and offsetOrigin in ol.style.Icon

This commit is contained in:
oterral
2014-05-08 14:20:19 +02:00
parent 38d8799a01
commit 71951b8bbd
4 changed files with 103 additions and 45 deletions
+15 -1
View File
@@ -40,6 +40,12 @@ ol.style.Circle = function(opt_options) {
*/
this.fill_ = goog.isDef(options.fill) ? options.fill : null;
/**
* @private
* @type {Array.<number>}
*/
this.origin_ = [0, 0];
/**
* @private
* @type {number}
@@ -74,7 +80,6 @@ ol.style.Circle = function(opt_options) {
goog.base(this, {
opacity: 1,
origin: [0, 0],
rotateWithView: false,
rotation: 0,
scale: 1,
@@ -128,6 +133,15 @@ ol.style.Circle.prototype.getImageState = function() {
};
/**
* @inheritDoc
* @todo api
*/
ol.style.Circle.prototype.getOrigin = function() {
return this.origin_;
};
/**
* @return {number} Radius.
* @todo api