Browse Source

[Bugfix] Fixed a problem with overloading x0vncserver by update requests, when video area is selected.


git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@2742 3789f03b-4d11-0410-bbf8-ca57d06f2519
tags/v0.0.90
Constantin Kaplinsky 15 years ago
parent
commit
2ef6695fe7
1 changed files with 13 additions and 2 deletions
  1. 13
    2
      common/rfb/VNCSConnectionST.cxx

+ 13
- 2
common/rfb/VNCSConnectionST.cxx View File

@@ -127,6 +127,17 @@ void VNCSConnectionST::processMessages()
processMsg();
}

// If there were update requests, try to send a framebuffer update.
// We don't send updates immediately on requests for two reasons:
// (1) If a video area is set, we don't want to send it on every
// update request. We should gobble all the pending update
// requests and send just one update.
// (2) This way, we give higher priority to user actions such as
// keyboard and pointer events.
if (!requested.is_empty()) {
writeFramebufferUpdate();
}

if (!clientsReadyBefore && !requested.is_empty())
server->desktop->framebufferUpdateRequest();
} catch (rdr::EndOfStream&) {
@@ -469,6 +480,8 @@ void VNCSConnectionST::framebufferUpdateRequest(const Rect& r,bool incremental)

SConnection::framebufferUpdateRequest(r, incremental);

// Just update the requested region.
// Framebuffer update will be sent a bit later, see processMessages().
Region reqRgn(r);
requested.assign_union(reqRgn);

@@ -477,8 +490,6 @@ void VNCSConnectionST::framebufferUpdateRequest(const Rect& r,bool incremental)
updates.add_changed(reqRgn);
server->comparer->add_changed(reqRgn);
}

writeFramebufferUpdate();
}

void VNCSConnectionST::setVideoRectangle(const Rect& r)

Loading…
Cancel
Save