ronin/scripts/modules/history.js
2016-12-19 14:25:30 -07:00

22 lines
338 B
JavaScript

function History(rune)
{
Module.call(this,rune);
this.lines = [];
this.active = function(cmd)
{
console.log(this.lines);
}
this.add = function(content)
{
this.lines.push(content);
}
this.widget = function()
{
if(this.lines.length === 0){ return "";}
return "^ "+this.lines.length+" ";
}
}