ret = this._basicRect(this._ctl, x, y, width, height,
sock, display, depth);
} else {
- throw Error("Illegal tight compression received (ctl: " +
+ throw new Error("Illegal tight compression received (ctl: " +
this._ctl + ")");
}
}
_pngRect(x, y, width, height, sock, display, depth) {
- throw Error("PNG received in standard Tight rect");
+ throw new Error("PNG received in standard Tight rect");
}
_basicRect(ctl, x, y, width, height, sock, display, depth) {
sock, display, depth);
break;
default:
- throw Error("Illegal tight filter received (ctl: " +
+ throw new Error("Illegal tight filter received (ctl: " +
this._filter + ")");
}
data = this._zlibs[streamId].inflate(data, true, uncompressedSize);
if (data.length != uncompressedSize) {
- throw Error("Incomplete zlib block");
+ throw new Error("Incomplete zlib block");
}
}
data = this._zlibs[streamId].inflate(data, true, uncompressedSize);
if (data.length != uncompressedSize) {
- throw Error("Incomplete zlib block");
+ throw new Error("Incomplete zlib block");
}
}
}
_gradientFilter(streamId, x, y, width, height, sock, display, depth) {
- throw Error("Gradient filter not implemented");
+ throw new Error("Gradient filter not implemented");
}
_readData(sock) {
export default class RFB extends EventTargetMixin {
constructor(target, url, options) {
if (!target) {
- throw Error("Must specify target");
+ throw new Error("Must specify target");
}
if (!url) {
- throw Error("Must specify URL");
+ throw new Error("Must specify URL");
}
super();