From 607f69c67a5b4dc72d2754192e3cdf67d0ad11d0 Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Tue, 3 Jun 2014 16:24:10 -0400 Subject: partitioning client and serveR --- .../assets/javascripts/mx/primitives/mx.tableau.js | 48 ++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 client/assets/javascripts/mx/primitives/mx.tableau.js (limited to 'client/assets/javascripts/mx/primitives/mx.tableau.js') diff --git a/client/assets/javascripts/mx/primitives/mx.tableau.js b/client/assets/javascripts/mx/primitives/mx.tableau.js new file mode 100644 index 0000000..514e206 --- /dev/null +++ b/client/assets/javascripts/mx/primitives/mx.tableau.js @@ -0,0 +1,48 @@ + + +var Tableau = function(){ + this.extend = extend.bind(Tableau) + + function extend (props) { + var Super = this + var ExtendedTableau = function () { + Super.call(this) + props.init && props.init.apply(this, arguments) + } + ExtendedTableau.prototype = Object.create(Tableau.prototype) + for (var prop in props) { + if (props.hasOwnProperty(prop) && prop !== 'init') { + ExtendedTableau.prototype[prop] = props[prop] + } + } + ExtendedTableau.extend = extend.bind(ExtendedTableau) + return ExtendedTableau + } +} + +Tableau.prototype.init = function(opt){} +Tableau.prototype.animate = function(t){} +Tableau.prototype.show = function(){} +Tableau.prototype.hide = function(){} + +MX.Tableau = new Tableau() +MX.Tableaux = {} + +/* + +MX.Tableaux.Foo = MX.Tableau.extend({ + // this will be called within the contructor + init: function (opt) { + }, + + show: function(){ + }, + + hide: function(){ + }, + + animate: function() { + } +}) + +*/ -- cgit v1.2.3-70-g09d2