- try {
- rfb = new RFB({'target': document.getElementById('noVNC_canvas'),
- 'encrypt': WebUtil.getConfigVar('encrypt',
- (window.location.protocol === "https:")),
- 'repeaterID': WebUtil.getConfigVar('repeaterID', ''),
- 'local_cursor': WebUtil.getConfigVar('cursor', true),
- 'shared': WebUtil.getConfigVar('shared', true),
- 'view_only': WebUtil.getConfigVar('view_only', false),
- 'onNotification': notification,
- 'onUpdateState': updateState,
- 'onDisconnected': disconnected,
- 'onXvpInit': xvpInit,
- 'onPasswordRequired': passwordRequired,
- 'onFBUComplete': FBUComplete,
- 'onDesktopName': updateDesktopName});
- } catch (exc) {
- status('Unable to create RFB client -- ' + exc, 'error');
- return; // don't continue trying to connect