2010-03-02 04:32:21 +08:00
|
|
|
if (typeof(window) === 'undefined') { var tree = require(require('path').join(__dirname, '..', '..', 'less', 'tree')); }
|
2010-02-24 02:39:05 +08:00
|
|
|
|
2010-03-02 04:32:21 +08:00
|
|
|
tree.Call = function Call(name, args) {
|
2010-02-24 02:39:05 +08:00
|
|
|
this.name = name;
|
|
|
|
this.args = args;
|
|
|
|
};
|
2010-03-02 08:47:32 +08:00
|
|
|
tree.Call.prototype = {
|
|
|
|
toCSS: function (context, env) {
|
2010-03-02 10:48:46 +08:00
|
|
|
var args = this.args.map(function (a) { return a.eval() });
|
|
|
|
return tree.functions[this.name].apply(tree.functions, args).toCSS();
|
2010-03-02 08:47:32 +08:00
|
|
|
}
|
|
|
|
};
|