# HG changeset patch # User Mikael Berthe # Date 1144568594 -7200 # Node ID 79c8823da808b2403dd7fe578eb7d0074ea84c6d # Parent b16acadd7d53725358b5442f817ce46c4f104121 Add "/msay toggle" command Toggles multi-line mode (msay begin/msay send), meant to be used for key bindings. diff -r b16acadd7d53 -r 79c8823da808 mcabber/src/commands.c --- a/mcabber/src/commands.c Sun Apr 09 09:22:40 2006 +0200 +++ b/mcabber/src/commands.c Sun Apr 09 09:43:14 2006 +0200 @@ -166,6 +166,7 @@ compl_add_category_word(COMPL_MULTILINE, "begin"); compl_add_category_word(COMPL_MULTILINE, "send"); compl_add_category_word(COMPL_MULTILINE, "send_to"); + compl_add_category_word(COMPL_MULTILINE, "toggle"); compl_add_category_word(COMPL_MULTILINE, "verbatim"); // Room category @@ -782,6 +783,13 @@ return; } + if (!strcasecmp(subcmd, "toggle")) { + if (scr_get_multimode()) + subcmd = "send"; + else + subcmd = "begin"; + } + if (!strcasecmp(subcmd, "abort")) { if (scr_get_multimode()) scr_LogPrint(LPRINT_NORMAL, "Leaving multi-line message mode.");