Added /room remove command, reformetted form output

This commit is contained in:
James Booth
2014-09-14 01:53:52 +01:00
parent 68b839a508
commit 7a12684523
5 changed files with 43 additions and 10 deletions

View File

@@ -470,6 +470,12 @@ _form_add_value(DataForm *form, const char * const tag, char *value)
}
}
static void
_form_remove_value(DataForm *form, const char * const tag, char *value)
{
// TODO
}
static gboolean
_form_field_contains_option(DataForm *form, const char * const tag, char *value)
{
@@ -503,6 +509,7 @@ form_init_module(void)
form_get_field_type = _form_get_field_type;
form_set_value = _form_set_value;
form_add_value = _form_add_value;
form_remove_value = _form_remove_value;
form_field_contains_option = _form_field_contains_option;
form_tag_exists = _form_tag_exists;
}

View File

@@ -210,6 +210,7 @@ void (*form_destroy)(DataForm *form);
char * (*form_get_form_type_field)(DataForm *form);
void (*form_set_value)(DataForm *form, const char * const tag, char *value);
void (*form_add_value)(DataForm *form, const char * const tag, char *value);
void (*form_remove_value)(DataForm *form, const char * const tag, char *value);
gboolean (*form_tag_exists)(DataForm *form, const char * const tag);
form_field_type_t (*form_get_field_type)(DataForm *form, const char * const tag);
gboolean (*form_field_contains_option)(DataForm *form, const char * const tag, char *value);