igniteui-angular-core
Version:
Ignite UI Angular Core logic used in multiple UI components.
54 lines (53 loc) • 1.96 kB
JavaScript
/*
THIS INFRAGISTICS ULTIMATE SOFTWARE LICENSE AGREEMENT ("AGREEMENT") LOCATED HERE:
https://www.infragistics.com/legal/license/igultimate-la
https://www.infragistics.com/legal/license/igultimate-eula
GOVERNS THE LICENSING, INSTALLATION AND USE OF INFRAGISTICS SOFTWARE. BY DOWNLOADING AND/OR INSTALLING AND USING INFRAGISTICS SOFTWARE: you are indicating that you have read and understand this Agreement, and agree to be legally bound by it on behalf of the yourself and your company.
*/
import { __extends } from "tslib";
import { Base, String_$type, markType } from "./type";
import { Dictionary$2 } from "./Dictionary$2";
/**
* @hidden
*/
var FontRegistry = /** @class */ /*@__PURE__*/ (function (_super) {
__extends(FontRegistry, _super);
function FontRegistry() {
var _this = _super !== null && _super.apply(this, arguments) || this;
_this.c = new Dictionary$2(String_$type, Base.$, 0);
return _this;
}
Object.defineProperty(FontRegistry, "instance", {
get: function () {
if (FontRegistry.a == null) {
FontRegistry.a = new FontRegistry();
}
return FontRegistry.a;
},
enumerable: false,
configurable: true
});
FontRegistry.prototype.registerFont = function (a, b) {
if (this.c.containsKey(a)) {
this.c.item(a, b);
}
else {
this.c.addItem(a, b);
}
};
FontRegistry.prototype.removeFont = function (a) {
if (this.c.containsKey(a)) {
this.c.removeItem(a);
}
};
FontRegistry.prototype.getFont = function (a) {
if (this.c.containsKey(a)) {
return this.c.item(a);
}
return null;
};
FontRegistry.$t = markType(FontRegistry, 'FontRegistry');
FontRegistry.a = null;
return FontRegistry;
}(Base));
export { FontRegistry };