Added a way to interrupt sending clipboard/file #4601

This commit is contained in:
Xinyu Hou
2015-05-23 00:34:00 +01:00
parent ff9ad5554a
commit fb3252efef
4 changed files with 69 additions and 4 deletions

View File

@@ -265,7 +265,11 @@ Client::leave()
m_screen->leave();
m_active = false;
if (m_sendClipboardThread != NULL) {
StreamChunker::interruptClipboard();
}
m_sendClipboardThread = new Thread(
new TMethodJob<Client>(
this,
@@ -803,6 +807,10 @@ Client::isReceivedFileSizeValid()
void
Client::sendFileToServer(const char* filename)
{
if (m_sendFileThread != NULL) {
StreamChunker::interruptFile();
}
m_sendFileThread = new Thread(
new TMethodJob<Client>(
this, &Client::sendFileThread,