summaryrefslogtreecommitdiff
path: root/src/plugins
diff options
context:
space:
mode:
authorSebastien Helleu <flashcode@flashtux.org>2010-12-26 12:16:47 +0100
committerSebastien Helleu <flashcode@flashtux.org>2010-12-26 12:16:47 +0100
commit391ca476742d17d9275ef4e02e9f7cce271697d4 (patch)
treea598c2a7261a787b686f81468e80e07d8942672a /src/plugins
parentb770f9c8c52e8af0d42ce94f25ab3d45d3f9b86b (diff)
downloadweechat-391ca476742d17d9275ef4e02e9f7cce271697d4.zip
Add info "weechat_upgrading", signal "upgrade_ended", display duration of upgrade
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/plugin-api.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/plugins/plugin-api.c b/src/plugins/plugin-api.c
index 9163120c9..7297a8829 100644
--- a/src/plugins/plugin-api.c
+++ b/src/plugins/plugin-api.c
@@ -322,6 +322,11 @@ plugin_api_info_get_internal (void *data, const char *info_name,
{
return WEECHAT_WEBSITE_DOWNLOAD;
}
+ else if (string_strcasecmp (info_name, "weechat_upgrading") == 0)
+ {
+ snprintf (value, sizeof (value), "%d", weechat_upgrading);
+ return value;
+ }
else if (string_strcasecmp (info_name, "charset_terminal") == 0)
{
return weechat_local_charset;
@@ -957,6 +962,8 @@ plugin_api_init ()
&plugin_api_info_get_internal, NULL);
hook_info (NULL, "weechat_site_download", N_("WeeChat site, download page"), NULL,
&plugin_api_info_get_internal, NULL);
+ hook_info (NULL, "weechat_upgrading", N_("1 if WeeChat is upgrading (command `/upgrade`)"), NULL,
+ &plugin_api_info_get_internal, NULL);
hook_info (NULL, "charset_terminal", N_("terminal charset"), NULL,
&plugin_api_info_get_internal, NULL);
hook_info (NULL, "charset_internal", N_("WeeChat internal charset"), NULL,