private void Connection_Disconnected(object sender, DisconnectedEventArgs e) { if (isConnected) IsConnected = false; if (isVersionValid) IsVersionValid = false; if (IsLoggedIn) IsLoggedIn = false; WriteLine("YOU HAS DISCONNECT"); }
private void Shitchat_Disconnected(object sender, DisconnectedEventArgs e) { }
private void Disconnect_Async(object sender, SocketAsyncEventArgs e) { DisconnectedEventArgs discArgs = new DisconnectedEventArgs(); discArgs.Reason = (string)e.UserToken; if (Disconnected != null) { if (syncContext != null) { syncContext.Post(new SendOrPostCallback(Disconnect_Sync), discArgs); } else { Disconnected(this, discArgs); } } }
static void shitchat_Disconnected(object sender, DisconnectedEventArgs e) { connected = false; loggedIn = false; versionValid = false; Console.WriteLine(e.Reason); }