about summary refs log tree commit diff stats
path: root/src/command/command.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/command/command.c')
-rw-r--r--src/command/command.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/command/command.c b/src/command/command.c
index 338fd27f..1a8d070f 100644
--- a/src/command/command.c
+++ b/src/command/command.c
@@ -115,6 +115,7 @@ static gboolean _cmd_set_intype(gchar **args, struct cmd_help_t help);
 static gboolean _cmd_set_flash(gchar **args, struct cmd_help_t help);
 static gboolean _cmd_set_splash(gchar **args, struct cmd_help_t help);
 static gboolean _cmd_set_chlog(gchar **args, struct cmd_help_t help);
+static gboolean _cmd_set_grlog(gchar **args, struct cmd_help_t help);
 static gboolean _cmd_set_history(gchar **args, struct cmd_help_t help);
 static gboolean _cmd_set_states(gchar **args, struct cmd_help_t help);
 static gboolean _cmd_set_outtype(gchar **args, struct cmd_help_t help);
@@ -597,6 +598,16 @@ static struct cmd_t setting_commands[] =
           "Switch chat logging on or off.",
           "This setting will be enabled if /history is set to on.",
           "When disabling this option, /history will also be disabled.",
+          "See the /grlog setting for enabling logging of chat room (groupchat) messages.",
+          NULL } } },
+
+    { "/grlog",
+        _cmd_set_grlog, parse_args, 1, 1,
+        { "/grlog on|off", "Chat logging of chat rooms to file",
+        { "/grlog on|off",
+          "-------------",
+          "Switch chat room logging on or off.",
+          "See the /chlog setting for enabling logging of one to one chat.",
           NULL } } },
 
     { "/states",
@@ -1107,6 +1118,8 @@ _cmd_complete_parameters(char *input, int *size)
         prefs_autocomplete_boolean_choice);
     _parameter_autocomplete(input, size, "/chlog",
         prefs_autocomplete_boolean_choice);
+    _parameter_autocomplete(input, size, "/grlog",
+        prefs_autocomplete_boolean_choice);
     _parameter_autocomplete(input, size, "/mouse",
         prefs_autocomplete_boolean_choice);
     _parameter_autocomplete(input, size, "/history",
@@ -2784,6 +2797,15 @@ _cmd_set_chlog(gchar **args, struct cmd_help_t help)
 }
 
 static gboolean
+_cmd_set_grlog(gchar **args, struct cmd_help_t help)
+{
+    gboolean result = _cmd_set_boolean_preference(args[0], help,
+        "Groupchat logging", PREF_GRLOG);
+
+    return result;
+}
+
+static gboolean
 _cmd_set_mouse(gchar **args, struct cmd_help_t help)
 {
     return _cmd_set_boolean_preference(args[0], help,