示例#1
0
        //CHANGED
        public async Task SendStreamDeckEvent(BaseStreamDeckArgs args)
        {
            var bytes = Encoding.UTF8.GetBytes(JsonConvert.SerializeObject(args));

            while (isSending)
            {
            }

            isSending = true;
            try
            {
                await _Socket.SendAsync(new ArraySegment <byte>(bytes), WebSocketMessageType.Text, true, CancellationToken.None);
            }
            catch (Exception ex)
            {
                throw ex;
            }
            finally
            {
                isSending = false;
            }
        }
示例#2
0
        public Task SendStreamDeckEvent(BaseStreamDeckArgs args)
        {
            var bytes = Encoding.UTF8.GetBytes(JsonConvert.SerializeObject(args));

            return(_Socket.SendAsync(new ArraySegment <byte>(bytes), WebSocketMessageType.Text, true, CancellationToken.None));
        }
示例#3
0
 public Task SendStreamDeckEvent(BaseStreamDeckArgs args)
 {
     throw new NotImplementedException();
 }