From 60b95b6e50d96902c6e642a3033ae60544f577e6 Mon Sep 17 00:00:00 2001 Message-Id: <60b95b6e50d96902c6e642a3033ae60544f577e6.1714965093.git.mdw@distorted.org.uk> From: Mark Wooding Date: Sun, 30 Sep 2007 14:37:43 +0100 Subject: [PATCH] update control buttons when disconnection detected Organization: Straylight/Edgeware From: rjk@greenend.org.uk <> --- disobedience/client.c | 2 ++ lib/eclient.c | 9 +++++++++ 2 files changed, 11 insertions(+) diff --git a/disobedience/client.c b/disobedience/client.c index 6ec4be5..ea0dbd9 100644 --- a/disobedience/client.c +++ b/disobedience/client.c @@ -110,6 +110,8 @@ static void gtkclient_poll(void *u, static void gtkclient_comms_error(void attribute((unused)) *u, const char *msg) { D(("gtkclient_comms_error %s", msg)); + /* Control buttons might have become unusable */ + control_update(); gtk_label_set_text(GTK_LABEL(report_label), msg); } diff --git a/lib/eclient.c b/lib/eclient.c index 43fafac..201da38 100644 --- a/lib/eclient.c +++ b/lib/eclient.c @@ -1138,6 +1138,15 @@ int disorder_eclient_search(disorder_eclient *c, /* Log clients ***************************************************************/ +/** @brief Monitor the server log + * @param c Client + * @param callbacks Functions to call when anything happens + * @param v Passed to @p callbacks functions + * + * Once a client is being used for logging it cannot be used for anything else. + * There is magic in authuser_opcallback() to re-submit the @c log command + * after reconnection. + */ int disorder_eclient_log(disorder_eclient *c, const disorder_eclient_log_callbacks *callbacks, void *v) { -- [mdw]