Skip to content

Commit e39eb24

Browse files
committed
Address copilot comments
1 parent 4cc7dbd commit e39eb24

File tree

1 file changed

+2
-9
lines changed
  • systemvm/agent/noVNC/app

1 file changed

+2
-9
lines changed

systemvm/agent/noVNC/app/ui.js

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1754,6 +1754,7 @@ const UI = {
17541754
},
17551755

17561756
_sendKeyUp(keysym, code) {
1757+
if (!UI.rfb) return;
17571758
UI.rfb.sendKey(keysym, code, false);
17581759
},
17591760

@@ -1774,7 +1775,7 @@ const UI = {
17741775

17751776
// Release all currently pressed modifier keys
17761777
_releaseAllModifierKeys() {
1777-
if (!UI.rfb || UI.rfb._rfbConnectionState !== 'connected') {
1778+
if (!UI.rfb) {
17781779
return false;
17791780
}
17801781

@@ -1786,14 +1787,6 @@ const UI = {
17861787
keysReleased = true;
17871788
}
17881789
}
1789-
1790-
// Also check RFB's internal shift state (it tracks this separately)
1791-
if (UI.rfb._shiftPressed) {
1792-
const shiftConfig = UI._modifierKeys.shift;
1793-
UI._sendKeyUp(shiftConfig.keysym, shiftConfig.code);
1794-
keysReleased = true;
1795-
}
1796-
17971790
return keysReleased;
17981791
},
17991792

0 commit comments

Comments
 (0)