X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=manifold%2Fstatic%2Fjs%2Fplugin.js;h=e27812956a1664e662c26e9cc9405805b66fdb3c;hb=03f7c0b84beda916f8bc9c5458d84673be24fb6e;hp=07ba9b7133750bd93c13f1140a6ca4f49f4276b4;hpb=4722ee62bd16b68846ecfc19e19e62b5bc769c01;p=myslice.git diff --git a/manifold/static/js/plugin.js b/manifold/static/js/plugin.js index 07ba9b71..e2781295 100644 --- a/manifold/static/js/plugin.js +++ b/manifold/static/js/plugin.js @@ -248,6 +248,15 @@ var Plugin = Class.extend({ return array[arguments.length + 1]; }, + // TOGGLE + // plugin-helper.js is about managing toggled state + // it would be beneficial to merge it in here + toggle_on: function () { return this.toggle("true"); }, + toggle_off: function () { return this.toggle("false"); }, + toggle: function (status) { + plugin_helper.set_toggle_status (this.options.plugin_uuid,status); + }, + /* SPIN */ spin: function() {