mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-08-02 08:57:53 -07:00
added admin tab; server status message update
This commit is contained in:
@@ -43,15 +43,16 @@ void RemoteClient::slotConnected()
|
||||
|
||||
void RemoteClient::loginResponse(ProtocolResponse *response)
|
||||
{
|
||||
Response_Login *resp = qobject_cast<Response_Login *>(response);
|
||||
if (!resp)
|
||||
disconnectFromServer();
|
||||
|
||||
if (resp->getResponseCode() == RespOk) {
|
||||
if (response->getResponseCode() == RespOk) {
|
||||
Response_Login *resp = qobject_cast<Response_Login *>(response);
|
||||
if (!resp) {
|
||||
disconnectFromServer();
|
||||
return;
|
||||
}
|
||||
setStatus(StatusLoggedIn);
|
||||
emit userInfoChanged(resp->getUserInfo());
|
||||
} else {
|
||||
emit serverError(resp->getResponseCode());
|
||||
emit serverError(response->getResponseCode());
|
||||
setStatus(StatusDisconnecting);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user