File tree Expand file tree Collapse file tree 3 files changed +16
-0
lines changed
Expand file tree Collapse file tree 3 files changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -282,6 +282,8 @@ const UI = {
282282 . addEventListener ( 'click' , UI . toggleExtraKeys ) ;
283283 document . getElementById ( "noVNC_toggle_ctrl_button" )
284284 . addEventListener ( 'click' , UI . toggleCtrl ) ;
285+ document . getElementById ( "noVNC_toggle_shift_button" )
286+ . addEventListener ( 'click' , UI . toggleShift ) ;
285287 document . getElementById ( "noVNC_toggle_windows_button" )
286288 . addEventListener ( 'click' , UI . toggleWindows ) ;
287289 document . getElementById ( "noVNC_toggle_alt_button" )
@@ -1551,6 +1553,17 @@ const UI = {
15511553 }
15521554 } ,
15531555
1556+ toggleShift ( ) {
1557+ const btn = document . getElementById ( 'noVNC_toggle_shift_button' ) ;
1558+ if ( btn . classList . contains ( "noVNC_selected" ) ) {
1559+ UI . sendKey ( KeyTable . XK_Shift_L , "ShiftLeft" , false ) ;
1560+ btn . classList . remove ( "noVNC_selected" ) ;
1561+ } else {
1562+ UI . sendKey ( KeyTable . XK_Shift_L , "ShiftLeft" , true ) ;
1563+ btn . classList . add ( "noVNC_selected" ) ;
1564+ }
1565+ } ,
1566+
15541567 toggleWindows ( ) {
15551568 const btn = document . getElementById ( 'noVNC_toggle_windows_button' ) ;
15561569 if ( btn . classList . contains ( "noVNC_selected" ) ) {
Original file line number Diff line number Diff line change @@ -107,6 +107,9 @@ <h1 class="noVNC_logo" translate="no" style="display: none;"><span>no</span><br>
107107 < input type ="image " alt ="Ctrl " src ="app/images/ctrl.png "
108108 id ="noVNC_toggle_ctrl_button " class ="noVNC_button "
109109 title ="Toggle Ctrl ">
110+ < input type ="image " alt ="Shift " src ="app/images/shift.png "
111+ id ="noVNC_toggle_shift_button " class ="noVNC_button "
112+ title ="Toggle Shift ">
110113 < input type ="image " alt ="Alt " src ="app/images/alt.png "
111114 id ="noVNC_toggle_alt_button " class ="noVNC_button "
112115 title ="Toggle Alt ">
You can’t perform that action at this time.
0 commit comments