/* istanbul ignore next */
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
define(["require", "exports", "./../pdf-color", "./../enum", "./pdf-brush"], function (require, exports, pdf_color_1, enum_1, pdf_brush_1) {
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var PdfSolidBrush = (function (_super) {
__extends(PdfSolidBrush, _super);
function PdfSolidBrush(color) {
var _this = _super.call(this) || this;
_this.pdfColor = color;
return _this;
}
Object.defineProperty(PdfSolidBrush.prototype, "color", {
get: function () {
return this.pdfColor;
},
set: function (value) {
this.pdfColor = value;
},
enumerable: true,
configurable: true
});
PdfSolidBrush.prototype.monitorChanges = function (brush, streamWriter, getResources, saveChanges, currentColorSpace) {
Iif (streamWriter == null) {
throw new Error('ArgumentNullException:streamWriter');
}
var diff = false;
Iif (brush == null) {
diff = true;
streamWriter.setColorAndSpace(this.pdfColor, currentColorSpace, false);
return diff;
}
else {
var sBrush = brush;
diff = true;
streamWriter.setColorAndSpace(this.pdfColor, currentColorSpace, false);
return diff;
}
};
PdfSolidBrush.prototype.resetChanges = function (streamWriter) {
streamWriter.setColorAndSpace(new pdf_color_1.PdfColor(0, 0, 0), enum_1.PdfColorSpace.Rgb, false);
};
return PdfSolidBrush;
}(pdf_brush_1.PdfBrush));
exports.PdfSolidBrush = PdfSolidBrush;
});
|