Send latest screen size with every update.

This commit is contained in:
Simo Kinnunen
2015-09-14 19:35:53 +09:00
parent 797e97e7c7
commit 692c043f6e
2 changed files with 18 additions and 8 deletions

View File

@@ -92,6 +92,7 @@ var StateReverse = Object.create(null), State = {
}
VncConnection.ENCODING_RAW = 0
VncConnection.ENCODING_DESKTOPSIZE = -223
Object.keys(State).map(function(name) {
VncConnection[name] = State[name]
@@ -122,6 +123,8 @@ VncConnection.prototype.writeFramebufferUpdate = function(rectangles) {
case VncConnection.ENCODING_RAW:
this._write(rect.data)
break
case VncConnection.ENCODING_DESKTOPSIZE:
break
default:
throw new Error(util.format(
'Unsupported encoding type', rect.encodingType))