Commit 3b2d43bf authored by David Schnur's avatar David Schnur

Provide a way for plugins to override classes.

parent edc2bbd9
...@@ -541,9 +541,16 @@ Licensed under the MIT license. ...@@ -541,9 +541,16 @@ Licensed under the MIT license.
} }
function initPlugins() { function initPlugins() {
// References to key classes, allowing plugins to modify them
var classes = {
Canvas: Canvas
};
for (var i = 0; i < plugins.length; ++i) { for (var i = 0; i < plugins.length; ++i) {
var p = plugins[i]; var p = plugins[i];
p.init(plot); p.init(plot, classes);
if (p.options) if (p.options)
$.extend(true, options, p.options); $.extend(true, options, p.options);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment