Properly decode ExtendedDesktopSize fields

We are expected to preserve these and use them in our requests back to
the server. We can't do that if we don't actually decode them correctly.
This commit is contained in:
Pierre Ossman 2023-06-04 14:54:40 +02:00
parent 0ccc679d32
commit 12d2e7832d
1 changed files with 6 additions and 6 deletions

View File

@ -2740,12 +2740,12 @@ export default class RFB extends EventTargetMixin {
for (let i = 0; i < numberOfScreens; i += 1) {
// Save the id and flags of the first screen
if (i === 0) {
this._screenID = this._sock.rQshiftBytes(4); // id
this._sock.rQskipBytes(2); // x-position
this._sock.rQskipBytes(2); // y-position
this._sock.rQskipBytes(2); // width
this._sock.rQskipBytes(2); // height
this._screenFlags = this._sock.rQshiftBytes(4); // flags
this._screenID = this._sock.rQshift32(); // id
this._sock.rQskipBytes(2); // x-position
this._sock.rQskipBytes(2); // y-position
this._sock.rQskipBytes(2); // width
this._sock.rQskipBytes(2); // height
this._screenFlags = this._sock.rQshift32(); // flags
} else {
this._sock.rQskipBytes(16);
}