Fix mouse focus issues.

This commit is contained in:
Joel Martin 2010-06-13 10:57:23 -05:00
parent 888d5813ed
commit 3954ae149a
2 changed files with 10 additions and 0 deletions

View File

@ -55,6 +55,13 @@ load: function(target) {
['',''])[1]; ['',''])[1];
$('VNC_encrypt').checked = (url.match(/encrypt=([A-Za-z0-9]*)/) || $('VNC_encrypt').checked = (url.match(/encrypt=([A-Za-z0-9]*)/) ||
['',''])[1]; ['',''])[1];
$('VNC_screen').onmousemove = function () {
// Unfocus clipboard when over the VNC area
if (RFB.clipboardFocus) {
$('VNC_clipboard_text').blur();
}
};
}, },
updateState: function(state, msg) { updateState: function(state, msg) {

3
vnc.js
View File

@ -1282,6 +1282,7 @@ mouseDown: function(e) {
RFB.mouse_arr = RFB.mouse_arr.concat( RFB.pointerEvent(x, y) ); RFB.mouse_arr = RFB.mouse_arr.concat( RFB.pointerEvent(x, y) );
RFB.flushClient(); RFB.flushClient();
return false;
}, },
mouseUp: function(e) { mouseUp: function(e) {
@ -1295,6 +1296,7 @@ mouseUp: function(e) {
RFB.mouse_arr = RFB.mouse_arr.concat( RFB.pointerEvent(x, y) ); RFB.mouse_arr = RFB.mouse_arr.concat( RFB.pointerEvent(x, y) );
RFB.flushClient(); RFB.flushClient();
return false;
}, },
mouseMove: function(e) { mouseMove: function(e) {
@ -1326,6 +1328,7 @@ mouseWheel: function (e) {
RFB.mouse_buttonMask ^= bmask; RFB.mouse_buttonMask ^= bmask;
RFB.mouse_arr = RFB.mouse_arr.concat( RFB.pointerEvent(x, y) ); RFB.mouse_arr = RFB.mouse_arr.concat( RFB.pointerEvent(x, y) );
RFB.flushClient(); RFB.flushClient();
return false;
}, },