restoring behavior of KasmVNC

This commit is contained in:
Kasm 2021-04-22 08:37:43 -04:00 committed by GitHub
parent 94c67f501f
commit c02aca5c13
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 4 deletions

View File

@ -10,7 +10,7 @@
import { toUnsigned32bit, toSigned32bit } from './util/int.js';
import * as Log from './util/logging.js';
import { encodeUTF8, decodeUTF8 } from './util/strings.js';
import { dragThreshold } from './util/browser.js';
import { dragThreshold, supportsCursorURIs, isTouchDevice } from './util/browser.js';
import { clientToElement } from './util/element.js';
import { setCapture } from './util/events.js';
import EventTargetMixin from './util/eventtarget.js';
@ -1935,10 +1935,12 @@ export default class RFB extends EventTargetMixin {
if (this.preferBandwidth) // must be last - server processes in reverse order
encs.push(encodings.pseudoEncodingPreferBandwidth);
if (this._fbDepth == 24) {
if (supportsCursorURIs && this._fbDepth == 24) {
if (this.preferLocalCursor || !isTouchDevice) {
encs.push(encodings.pseudoEncodingVMwareCursor);
encs.push(encodings.pseudoEncodingCursor);
}
}
RFB.messages.clientEncodings(this._sock, encs);
}