carto/lib/less/node/call.js

13 lines
425 B
JavaScript
Raw Normal View History

if (typeof(window) === 'undefined') { var tree = require(require('path').join(__dirname, '..', '..', 'less', 'tree')); }
2010-02-24 02:39:05 +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) {
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
}
};