1
0
mirror of https://github.com/Sonarr/Sonarr.git synced 2024-12-16 11:37:58 +02:00
Sonarr/UI/Mixins/AsChangeTrackingModel.js
2013-06-18 18:02:23 -07:00

32 lines
616 B
JavaScript

'use strict';
define(
function () {
return function () {
var originalInit = this.prototype.initialize;
this.prototype.initialize = function () {
this.isSaved = true;
this.on('change', function () {
this.isSaved = false;
}, this);
this.on('sync', function () {
this.isSaved = true;
}, this);
if (originalInit) {
originalInit.call(this);
}
};
return this;
};
}
);