| var Button_Animation = (function () { function Button_Animation() { } Button_Animation.prototype.ChangeColor = function () { var _this = this; document.getElementById('buttonchange').style.backgroundColor = "Blue"; document.getElementById('buttonchange').style.color = "White"; setTimeout(function () { _this.Change(); }, 1000); }; Button_Animation.prototype.Change = function () { var _this = this; document.getElementById('buttonchange').style.backgroundColor = "Purple"; document.getElementById('buttonchange').style.color = "White"; setTimeout(function () { _this.otherChange(); }, 1000); }; Button_Animation.prototype.otherChange = function () { document.getElementById('buttonchange').style.backgroundColor = "Red"; document.getElementById('buttonchange').style.color = "Black"; }; Button_Animation.prototype.HideColor = function () { document.getElementById('buttonchange').style.backgroundColor = "green"; document.getElementById('buttonchange').style.color = "Black"; }; return Button_Animation; })(); window.onload = function () { var obj = new Button_Animation(); var b = (document.getElementById("buttonchange")); b.onmouseover = function () { obj.ChangeColor(); }; b.onmouseout = function () { obj.HideColor(); }; }; //@ sourceMappingURL=app.js.map |