Exemplo n.º 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;
            }
        }
Exemplo n.º 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));
        }
Exemplo n.º 3
0
 public Task SendStreamDeckEvent(BaseStreamDeckArgs args)
 {
     throw new NotImplementedException();
 }