mirror of
https://github.com/weyne85/rustdesk.git
synced 2025-10-29 17:00:05 +00:00
win_fix_multi_tab: refactor clipboard on windows, init debug done
Signed-off-by: fufesou <shuanglongchen@yeah.net>
This commit is contained in:
@@ -64,7 +64,8 @@ fn check_clipboard_file_context(enable_file_transfer: bool) {
|
||||
let mut lock = CLIPBOARD_FILE_CONTEXT.lock().unwrap();
|
||||
if enabled {
|
||||
if *lock == 0 {
|
||||
match clipboard::create_cliprdr_context(true, false) {
|
||||
match clipboard::create_cliprdr_context(true, false, clipboard::ProcessSide::ClientSide)
|
||||
{
|
||||
Ok(context) => {
|
||||
log::info!("clipboard context for file transfer created.");
|
||||
*lock = Box::into_raw(context) as _;
|
||||
|
||||
@@ -730,7 +730,7 @@ pub async fn start_clipboard_file(mut rx: mpsc::UnboundedReceiver<ClipboardFileD
|
||||
}
|
||||
Some(ClipboardFileData::Enable((id, enabled))) => {
|
||||
if enabled && cliprdr_context.is_none() {
|
||||
cliprdr_context = Some(match clipboard::create_cliprdr_context(true, false) {
|
||||
cliprdr_context = Some(match clipboard::create_cliprdr_context(true, false, clipboard::ProcessSide::ServerSide) {
|
||||
Ok(context) => {
|
||||
log::info!("clipboard context for file transfer created.");
|
||||
context
|
||||
|
||||
Reference in New Issue
Block a user