xC/xP: show own user's info in frontends

This commit is contained in:
2022-09-20 17:14:55 +02:00
parent 7806d4bd4e
commit 9327333813
3 changed files with 53 additions and 15 deletions

View File

@@ -155,13 +155,25 @@ struct EventMessage {
case SERVER_UPDATE:
string server_name;
enum ServerState {
union ServerData switch (enum ServerState {
DISCONNECTED,
CONNECTING,
CONNECTED,
REGISTERED,
DISCONNECTING,
} state;
} state) {
case DISCONNECTED:
case CONNECTING:
case CONNECTED:
void;
case REGISTERED:
string user;
string user_mode;
// Theoretically, we could also send user information in this state,
// but we'd have to duplicate both fields.
case DISCONNECTING:
void;
} data;
case SERVER_RENAME:
// Buffers aren't sent updates for in this circumstance,
// as that wouldn't be sufficiently atomic anyway.