This is an automated email from the ASF dual-hosted git repository.

ovilia pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-echarts.git


The following commit(s) were added to refs/heads/master by this push:
     new ece525c  fix(polarBar): fix polar.center
ece525c is described below

commit ece525c5bf33199f1974fe3a09ca8354d5ce3d1d
Author: Ovilia <zwl.s...@gmail.com>
AuthorDate: Mon Aug 27 20:37:16 2018 +0800

    fix(polarBar): fix polar.center
---
 src/layout/barPolar.js           | 5 ++---
 test/bar-polar-basic-radial.html | 1 +
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/layout/barPolar.js b/src/layout/barPolar.js
index a08e022..00e4401 100644
--- a/src/layout/barPolar.js
+++ b/src/layout/barPolar.js
@@ -70,9 +70,8 @@ function barLayoutPolar(seriesType, ecModel, api) {
         var columnWidth = columnLayoutInfo.width;
         var valueAxis = polar.getOtherAxis(baseAxis);
 
-        var center = seriesModel.get('center') || ['50%', '50%'];
-        var cx = parsePercent(center[0], width);
-        var cy = parsePercent(center[1], height);
+        var cx = seriesModel.coordinateSystem.cx;
+        var cy = seriesModel.coordinateSystem.cy;
 
         var barMinHeight = seriesModel.get('barMinHeight') || 0;
         var barMinAngle = seriesModel.get('barMinAngle') || 0;
diff --git a/test/bar-polar-basic-radial.html b/test/bar-polar-basic-radial.html
index 54a1a7c..da70fa3 100644
--- a/test/bar-polar-basic-radial.html
+++ b/test/bar-polar-basic-radial.html
@@ -59,6 +59,7 @@ under the License.
                     radiusAxis: {
                     },
                     polar: {
+                        center: ['40%', '50%']
                     },
                     series: [{
                         type: 'bar',


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@echarts.apache.org
For additional commands, e-mail: commits-h...@echarts.apache.org

Reply via email to