summaryrefslogtreecommitdiff
path: root/addons/web/static/src/js/views/graph/graph_renderer.js
diff options
context:
space:
mode:
authorMathieu Duckerts-Antoine <dam@odoo.com>2019-06-05 13:48:04 +0000
committerVincent Schippefilt <vsc@odoo.com>2019-07-30 06:53:11 +0000
commit4302f4dc1c28b218d46a3bbf0c4f8cac132137fc (patch)
tree06f15ea2fa9f2a07b062d96ea6d9545cb24a8536 /addons/web/static/src/js/views/graph/graph_renderer.js
parent21944479a239d00d2d51deb38deb6f16c8337f30 (diff)
[REF] web: review inline doc of graph renderer
Diffstat (limited to 'addons/web/static/src/js/views/graph/graph_renderer.js')
-rw-r--r--addons/web/static/src/js/views/graph/graph_renderer.js10
1 files changed, 3 insertions, 7 deletions
diff --git a/addons/web/static/src/js/views/graph/graph_renderer.js b/addons/web/static/src/js/views/graph/graph_renderer.js
index 269f6993189..6654b84e8da 100644
--- a/addons/web/static/src/js/views/graph/graph_renderer.js
+++ b/addons/web/static/src/js/views/graph/graph_renderer.js
@@ -82,13 +82,9 @@ return AbstractRenderer.extend({
return this._super.apply(this, arguments);
},
/**
- * The graph view uses the Chart.js lib to render the graph. This lib requires
- * that the rendering is done directly into the DOM (so that it can correctly
- * compute positions). However, the views are always rendered in fragments,
- * and appended to the DOM once ready (to prevent them from flickering). We
- * here use the on_attach_callback hook, called when the widget is attached
- * to the DOM, to perform the rendering. This ensures that the rendering is
- * always done in the DOM.
+ * Chart.js does not need the canevas to be in dom in order
+ * to be able to work well. We could avoid the calls to on_attach_callback
+ * and on_detach_callback.
*
* @override
*/