Added thread synchronization to local and remote clipboard update events