1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-12 14:14:48 +02:00

Refresh screen when exiting WeeChat (to display messages printed after /quit)

This commit is contained in:
Sebastien Helleu
2010-03-20 17:09:07 +01:00
parent 9d96090d7d
commit 7925b2d242
21 changed files with 184 additions and 50 deletions
+2
View File
@@ -22,6 +22,8 @@ Version 0.3.2 (under dev!)
string_is_command_char and string_input_for_buffer in plugin and script API
* core: add new option weechat.look.read_marker_always_show
* core: use arguments for infolist "nicklist" to return only one nick or group
* gui: refresh screen when exiting WeeChat (to display messages printed after
/quit)
* gui: fix bug with global history, reset pointer to last entry after each user
input (bug #28754)
* gui: fix bug with bar background after text with background color (bug #28157)
+9 -1
View File
@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.3.2-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2010-03-19 13:59+0100\n"
"POT-Creation-Date: 2010-03-20 17:06+0100\n"
"PO-Revision-Date: 2010-03-05 10:43+0100\n"
"Last-Translator: Jiri Golembiovsky <golemj@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -5448,6 +5448,10 @@ msgstr "Plugin \"%s\" odebrán"
msgid "%sError: plugin \"%s\" not found"
msgstr "%sChyba: plugin \"%s\" nenalezen"
#, fuzzy
msgid "Plugins unloaded"
msgstr "Načtené pluginy:"
msgid "Actions (letter+enter):"
msgstr "Akce (písmeno+enter):"
@@ -5872,6 +5876,10 @@ msgstr " napsal \"%s\", licence: %s"
msgid " (none)"
msgstr " (žádný)"
#, fuzzy, c-format
msgid "%s: scripts unloaded"
msgstr "%s: skript \"%s\" odebrán"
#, c-format
msgid ""
"%s%s: unable to call function \"%s\", script is not initialized (script: %s)"
+9 -1
View File
@@ -10,7 +10,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.3.2-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2010-03-19 13:59+0100\n"
"POT-Creation-Date: 2010-03-20 17:06+0100\n"
"PO-Revision-Date: 2010-03-04 10:19+0100\n"
"Last-Translator: Nils G <weechatter@arcor.de>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -5645,6 +5645,10 @@ msgstr "Erweiterung \"%s\" wurde deinstalliert"
msgid "%sError: plugin \"%s\" not found"
msgstr "%sFehler: Die Erweiterung \"%s\" wurde nicht gefunden"
#, fuzzy
msgid "Plugins unloaded"
msgstr "Installierte Erweiterungen:"
msgid "Actions (letter+enter):"
msgstr "Aktion (Zeichen+Enter):"
@@ -6076,6 +6080,10 @@ msgstr " geschrieben von \"%s\", Lizenz: %s"
msgid " (none)"
msgstr " (keine)"
#, fuzzy, c-format
msgid "%s: scripts unloaded"
msgstr "%s: Das Skript \"%s\" wurde deinstalliert"
#, c-format
msgid ""
"%s%s: unable to call function \"%s\", script is not initialized (script: %s)"
+9 -1
View File
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.3.2-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2010-03-19 13:59+0100\n"
"POT-Creation-Date: 2010-03-20 17:06+0100\n"
"PO-Revision-Date: 2010-02-23 10:43+0100\n"
"Last-Translator: Elián Hanisch <lambdae2@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -5508,6 +5508,10 @@ msgstr "Plugin \"%s\" descargado"
msgid "%sError: plugin \"%s\" not found"
msgstr "%sError: plugin \"%s\" no encontrado"
#, fuzzy
msgid "Plugins unloaded"
msgstr "Plugins cargados:"
msgid "Actions (letter+enter):"
msgstr "Acciones (letra+enter)"
@@ -5940,6 +5944,10 @@ msgstr " escrito por \"%s\", licencia: %s"
msgid " (none)"
msgstr " (ninguno)"
#, fuzzy, c-format
msgid "%s: scripts unloaded"
msgstr "%s: script \"%s\" descargado"
#, c-format
msgid ""
"%s%s: unable to call function \"%s\", script is not initialized (script: %s)"
+9 -2
View File
@@ -6,8 +6,8 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.3.2-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2010-03-19 13:59+0100\n"
"PO-Revision-Date: 2010-03-14 16:44+0100\n"
"POT-Creation-Date: 2010-03-20 17:06+0100\n"
"PO-Revision-Date: 2010-03-20 16:33+0100\n"
"Last-Translator: FlashCode <flashcode@flashtux.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
"MIME-Version: 1.0\n"
@@ -5571,6 +5571,9 @@ msgstr "Extension \"%s\" déchargée"
msgid "%sError: plugin \"%s\" not found"
msgstr "%sErreur: extension \"%s\" non trouvée"
msgid "Plugins unloaded"
msgstr "Extensions déchargées"
msgid "Actions (letter+enter):"
msgstr "Actions (lettre+entrée):"
@@ -6004,6 +6007,10 @@ msgstr " écrit par \"%s\", licence: %s"
msgid " (none)"
msgstr " (aucun)"
#, c-format
msgid "%s: scripts unloaded"
msgstr "%s: scripts déchargés"
#, c-format
msgid ""
"%s%s: unable to call function \"%s\", script is not initialized (script: %s)"
+9 -1
View File
@@ -12,7 +12,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.3.2-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2010-03-19 13:59+0100\n"
"POT-Creation-Date: 2010-03-20 17:06+0100\n"
"PO-Revision-Date: 2010-02-23 10:43+0100\n"
"Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -5310,6 +5310,10 @@ msgstr "A \"%s\" modul eltávolítva.\n"
msgid "%sError: plugin \"%s\" not found"
msgstr "%s a \"%s\" modul nem található\n"
#, fuzzy
msgid "Plugins unloaded"
msgstr "Betöltött modulok:\n"
msgid "Actions (letter+enter):"
msgstr ""
@@ -5735,6 +5739,10 @@ msgstr ""
msgid " (none)"
msgstr "(ismeretlen)"
#, fuzzy, c-format
msgid "%s: scripts unloaded"
msgstr "A \"%s\" modul eltávolítva.\n"
#, fuzzy, c-format
msgid ""
"%s%s: unable to call function \"%s\", script is not initialized (script: %s)"
+9 -1
View File
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Weechat 0.3.2-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2010-03-19 13:59+0100\n"
"POT-Creation-Date: 2010-03-20 17:06+0100\n"
"PO-Revision-Date: 2010-02-23 10:43+0100\n"
"Last-Translator: Marco Paolone <marcopaolone@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -5499,6 +5499,10 @@ msgstr "Plugin \"%s\" disattivato"
msgid "%sError: plugin \"%s\" not found"
msgstr "%sErrore: plugin \"%s\" non trovato"
#, fuzzy
msgid "Plugins unloaded"
msgstr "Plugin caricati:"
msgid "Actions (letter+enter):"
msgstr "Azioni (lettera+invio)"
@@ -5927,6 +5931,10 @@ msgstr " scritto da \"%s\", licenza: %s"
msgid " (none)"
msgstr " (nessuno)"
#, fuzzy, c-format
msgid "%s: scripts unloaded"
msgstr "%s: script \"%s\" disattivato"
#, c-format
msgid ""
"%s%s: unable to call function \"%s\", script is not initialized (script: %s)"
+9 -1
View File
@@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.3.0-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2010-03-19 13:59+0100\n"
"POT-Creation-Date: 2010-03-20 17:06+0100\n"
"PO-Revision-Date: 2010-02-23 10:43+0100\n"
"Last-Translator: Krzysztof Koroscik <soltys@szluug.org>\n"
"Language-Team: Polish\n"
@@ -5489,6 +5489,10 @@ msgstr "Wtyczka \"%s\" wyładowana"
msgid "%sError: plugin \"%s\" not found"
msgstr "%sBłąd: nie znaleziono wtyczki \"%s\""
#, fuzzy
msgid "Plugins unloaded"
msgstr "Załadowane pluginy:"
msgid "Actions (letter+enter):"
msgstr "Akcje (litera+enter)"
@@ -5916,6 +5920,10 @@ msgstr " napisane przez \"%s\", licencja: %s"
msgid " (none)"
msgstr "(żaden)"
#, fuzzy, c-format
msgid "%s: scripts unloaded"
msgstr "%s: skrypt \"%s\" wyładowano"
#, c-format
msgid ""
"%s%s: unable to call function \"%s\", script is not initialized (script: %s)"
+9 -1
View File
@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.3.2-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2010-03-19 13:59+0100\n"
"POT-Creation-Date: 2010-03-20 17:06+0100\n"
"PO-Revision-Date: 2010-02-23 10:43+0100\n"
"Last-Translator: Pavel Shevchuk <stlwrt@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -5313,6 +5313,10 @@ msgstr "Plugin \"%s\" выгружен.\n"
msgid "%sError: plugin \"%s\" not found"
msgstr "%s plugin \"%s\" не найден\n"
#, fuzzy
msgid "Plugins unloaded"
msgstr "Загруженные plugin'ы\n"
msgid "Actions (letter+enter):"
msgstr ""
@@ -5738,6 +5742,10 @@ msgstr ""
msgid " (none)"
msgstr "(неизвестен)"
#, fuzzy, c-format
msgid "%s: scripts unloaded"
msgstr "Plugin \"%s\" выгружен.\n"
#, fuzzy, c-format
msgid ""
"%s%s: unable to call function \"%s\", script is not initialized (script: %s)"
+8 -1
View File
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2010-03-19 13:59+0100\n"
"POT-Creation-Date: 2010-03-20 17:06+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -4604,6 +4604,9 @@ msgstr ""
msgid "%sError: plugin \"%s\" not found"
msgstr ""
msgid "Plugins unloaded"
msgstr ""
msgid "Actions (letter+enter):"
msgstr ""
@@ -5006,6 +5009,10 @@ msgstr ""
msgid " (none)"
msgstr ""
#, c-format
msgid "%s: scripts unloaded"
msgstr ""
#, c-format
msgid ""
"%s%s: unable to call function \"%s\", script is not initialized (script: %s)"
+1
View File
@@ -3471,6 +3471,7 @@ command_upgrade (void *data, struct t_gui_buffer *buffer,
exec_args[3] = strdup (weechat_home);
weechat_quit = 1;
weechat_upgrading = 1;
/* save layout, unload plugins, save config, then upgrade */
gui_layout_save_on_exit ();
+11
View File
@@ -349,6 +349,17 @@ gui_main_end (int clean_exit)
{
if (clean_exit)
{
/*
* final refreshs, to see messages just before exiting
* (if we are upgrading, don't refresh anything!)
*/
if (!weechat_upgrading)
{
gui_main_refreshs ();
if (gui_window_refresh_needed)
gui_main_refreshs ();
}
/* remove bar items and bars */
gui_bar_item_end ();
gui_bar_free_all ();
+1 -1
View File
@@ -1659,7 +1659,7 @@ gui_buffer_close (struct t_gui_buffer *buffer)
ptr_window = ptr_window->next_window)
{
if (ptr_window->buffer == buffer)
ptr_window->buffer = NULL;
ptr_window->buffer = gui_buffers;
}
hook_signal_send ("buffer_closed",
+17 -3
View File
@@ -840,9 +840,12 @@ plugin_unload (struct t_weechat_plugin *plugin)
plugin_remove (plugin);
gui_chat_printf (NULL,
_("Plugin \"%s\" unloaded"),
(name) ? name : "???");
if ((weechat_debug_core >= 1) || !plugin_quiet)
{
gui_chat_printf (NULL,
_("Plugin \"%s\" unloaded"),
(name) ? name : "???");
}
if (name)
free (name);
}
@@ -875,10 +878,21 @@ plugin_unload_name (const char *name)
void
plugin_unload_all ()
{
int plugins_loaded;
plugins_loaded = (weechat_plugins) ? 1 : 0;
plugin_quiet = 1;
while (weechat_plugins)
{
plugin_unload (last_weechat_plugin);
}
plugin_quiet = 0;
if (plugins_loaded)
{
gui_chat_printf (NULL, _("Plugins unloaded"));
}
}
/*
+9 -7
View File
@@ -305,9 +305,12 @@ weechat_lua_unload (struct t_plugin_script *script)
char *lua_argv[1] = { NULL };
void *interpreter;
weechat_printf (NULL,
weechat_gettext ("%s: unloading script \"%s\""),
LUA_PLUGIN_NAME, script->name);
if ((weechat_lua_plugin->debug >= 1) || !lua_quiet)
{
weechat_printf (NULL,
weechat_gettext ("%s: unloading script \"%s\""),
LUA_PLUGIN_NAME, script->name);
}
if (script->shutdown_func && script->shutdown_func[0])
{
@@ -676,11 +679,10 @@ weechat_plugin_init (struct t_weechat_plugin *plugin, int argc, char *argv[])
int
weechat_plugin_end (struct t_weechat_plugin *plugin)
{
/* make C compiler happy */
(void) plugin;
/* unload all scripts */
weechat_lua_unload_all ();
lua_quiet = 1;
script_end (plugin, &lua_scripts, &weechat_lua_unload_all);
lua_quiet = 0;
return WEECHAT_RC_OK;
}
+10 -8
View File
@@ -432,10 +432,13 @@ weechat_perl_unload (struct t_plugin_script *script)
int *r;
char *perl_argv[1] = { NULL };
void *interpreter;
weechat_printf (NULL,
weechat_gettext ("%s: unloading script \"%s\""),
PERL_PLUGIN_NAME, script->name);
if ((weechat_perl_plugin->debug >= 1) || !perl_quiet)
{
weechat_printf (NULL,
weechat_gettext ("%s: unloading script \"%s\""),
PERL_PLUGIN_NAME, script->name);
}
#ifdef MULTIPLICITY
PERL_SET_CONTEXT (script->interpreter);
@@ -871,11 +874,10 @@ weechat_plugin_init (struct t_weechat_plugin *plugin, int argc, char *argv[])
int
weechat_plugin_end (struct t_weechat_plugin *plugin)
{
/* make C compiler happy */
(void) plugin;
/* unload all scripts */
weechat_perl_unload_all ();
perl_quiet = 1;
script_end (plugin, &perl_scripts, &weechat_perl_unload_all);
perl_quiet = 0;
#ifndef MULTIPLICITY
/* free perl intepreter */
+9 -7
View File
@@ -537,9 +537,12 @@ weechat_python_unload (struct t_plugin_script *script)
void *interpreter;
PyThreadState *old_interpreter;
weechat_printf (NULL,
weechat_gettext ("%s: unloading script \"%s\""),
PYTHON_PLUGIN_NAME, script->name);
if ((weechat_python_plugin->debug >= 1) || !python_quiet)
{
weechat_printf (NULL,
weechat_gettext ("%s: unloading script \"%s\""),
PYTHON_PLUGIN_NAME, script->name);
}
if (script->shutdown_func && script->shutdown_func[0])
{
@@ -943,11 +946,10 @@ weechat_plugin_init (struct t_weechat_plugin *plugin, int argc, char *argv[])
int
weechat_plugin_end (struct t_weechat_plugin *plugin)
{
/* make C compiler happy */
(void) plugin;
/* unload all scripts */
weechat_python_unload_all ();
python_quiet = 1;
script_end (plugin, &python_scripts, &weechat_python_unload_all);
python_quiet = 0;
/* free Python interpreter */
if (python_mainThreadState != NULL)
+9 -7
View File
@@ -592,9 +592,12 @@ weechat_ruby_unload (struct t_plugin_script *script)
char *ruby_argv[1] = { NULL };
void *interpreter;
weechat_printf (NULL,
weechat_gettext ("%s: unloading script \"%s\""),
RUBY_PLUGIN_NAME, script->name);
if ((weechat_ruby_plugin->debug >= 1) || !ruby_quiet)
{
weechat_printf (NULL,
weechat_gettext ("%s: unloading script \"%s\""),
RUBY_PLUGIN_NAME, script->name);
}
if (script->shutdown_func && script->shutdown_func[0])
{
@@ -1063,11 +1066,10 @@ weechat_plugin_init (struct t_weechat_plugin *plugin, int argc, char *argv[])
int
weechat_plugin_end (struct t_weechat_plugin *plugin)
{
/* make C compiler happy */
(void) plugin;
/* unload all scripts */
weechat_ruby_unload_all ();
ruby_quiet = 1;
script_end (plugin, &ruby_scripts, &weechat_ruby_unload_all);
ruby_quiet = 0;
ruby_cleanup (0);
+23 -1
View File
@@ -172,7 +172,7 @@ script_upgrade_set_buffer_callbacks (struct t_weechat_plugin *weechat_plugin,
}
/*
* script_init: initialize script
* script_init: initialize script plugin
*/
void
@@ -1238,6 +1238,28 @@ script_infolist_list_scripts (struct t_weechat_plugin *weechat_plugin,
return NULL;
}
/*
* script_end: end script plugin
*/
void
script_end (struct t_weechat_plugin *weechat_plugin,
struct t_plugin_script **scripts,
void (*callback_unload_all)())
{
int scripts_loaded;
scripts_loaded = (*scripts) ? 1 : 0;
(void)(callback_unload_all) ();
if (scripts_loaded)
{
weechat_printf (NULL, _("%s: scripts unloaded"),
weechat_plugin->name);
}
}
/*
* script_print_log: print script infos in log (usually for crash dump)
*/
+3
View File
@@ -143,6 +143,9 @@ extern struct t_infolist *script_infolist_list_scripts (struct t_weechat_plugin
struct t_plugin_script *scripts,
void *pointer,
const char *arguments);
extern void script_end (struct t_weechat_plugin *weechat_plugin,
struct t_plugin_script **scripts,
void (*callback_unload_all)());
extern void script_print_log (struct t_weechat_plugin *weechat_plugin,
struct t_plugin_script *scripts);
+9 -6
View File
@@ -240,9 +240,12 @@ weechat_tcl_unload (struct t_plugin_script *script)
Tcl_Interp* interp;
void *pointer;
weechat_printf (NULL,
weechat_gettext ("%s: unloading script \"%s\""),
TCL_PLUGIN_NAME, script->name);
if ((weechat_tcl_plugin->debug >= 1) || !tcl_quiet)
{
weechat_printf (NULL,
weechat_gettext ("%s: unloading script \"%s\""),
TCL_PLUGIN_NAME, script->name);
}
if (script->shutdown_func && script->shutdown_func[0])
{
@@ -611,10 +614,10 @@ weechat_plugin_init (struct t_weechat_plugin *plugin, int argc, char *argv[])
int
weechat_plugin_end (struct t_weechat_plugin *plugin)
{
(void) plugin;
/* unload all scripts */
weechat_tcl_unload_all ();
tcl_quiet = 1;
script_end (plugin, &tcl_scripts, &weechat_tcl_unload_all);
tcl_quiet = 0;
return WEECHAT_RC_OK;
}