-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Open
Labels
Milestone
Description
I have implemented code to change legend positions (on "postRender" event) and it was working fine with dc 1.7.4 version but now I am wondering why in dc 2.0.0-beta.30, there is a render call for legends in _chart.redraw function which causes for me to call my legend position code each time even on applying filters. Code specifically in
_chart.redraw = function () {
sizeSvg();
_listeners.preRedraw(_chart);
var result = _chart._doRedraw();
if (_legend) {
_legend.render();
}
_chart._activateRenderlets('postRedraw');
return result;
};
I believe during redrawing of charts or applying filters, legend rendering won't be needed, only in rendering of charts would we need this legend rendering. So my question is do we still need this rendering?
if (_legend) { _legend.render(); }
Or I might be missing something so may I know why we are using this above condition in redrawing?