mirror of
https://git.jabber.space/devs/cproof.git
synced 2026-07-20 23:26:21 +00:00
Renamed mucconfwin functions
This commit is contained in:
@@ -39,10 +39,10 @@
|
||||
#include "ui/win_types.h"
|
||||
#include "window_list.h"
|
||||
|
||||
static void _ui_handle_form_field(ProfWin *window, char *tag, FormField *field);
|
||||
static void _mucconfwin_form_field(ProfWin *window, char *tag, FormField *field);
|
||||
|
||||
void
|
||||
ui_show_form(ProfMucConfWin *confwin)
|
||||
mucconfwin_show_form(ProfMucConfWin *confwin)
|
||||
{
|
||||
ProfWin *window = (ProfWin*) confwin;
|
||||
if (confwin->form->title) {
|
||||
@@ -53,7 +53,7 @@ ui_show_form(ProfMucConfWin *confwin)
|
||||
}
|
||||
win_print(window, '-', 0, NULL, 0, 0, "", "");
|
||||
|
||||
ui_show_form_help(confwin);
|
||||
mucconfwin_form_help(confwin);
|
||||
|
||||
GSList *fields = confwin->form->fields;
|
||||
GSList *curr_field = fields;
|
||||
@@ -67,7 +67,7 @@ ui_show_form(ProfMucConfWin *confwin)
|
||||
}
|
||||
} else if (g_strcmp0(field->type, "hidden") != 0 && field->var) {
|
||||
char *tag = g_hash_table_lookup(confwin->form->var_to_tag, field->var);
|
||||
_ui_handle_form_field(window, tag, field);
|
||||
_mucconfwin_form_field(window, tag, field);
|
||||
}
|
||||
|
||||
curr_field = g_slist_next(curr_field);
|
||||
@@ -75,22 +75,22 @@ ui_show_form(ProfMucConfWin *confwin)
|
||||
}
|
||||
|
||||
void
|
||||
ui_show_form_field(ProfWin *window, DataForm *form, char *tag)
|
||||
mucconfwin_show_form_field(ProfWin *window, DataForm *form, char *tag)
|
||||
{
|
||||
FormField *field = form_get_field_by_tag(form, tag);
|
||||
_ui_handle_form_field(window, tag, field);
|
||||
_mucconfwin_form_field(window, tag, field);
|
||||
win_println(window, 0, "");
|
||||
}
|
||||
|
||||
void
|
||||
ui_handle_room_configuration(const char *const roomjid, DataForm *form)
|
||||
mucconfwin_handle_configuration(const char *const roomjid, DataForm *form)
|
||||
{
|
||||
ProfWin *window = wins_new_muc_config(roomjid, form);
|
||||
ProfMucConfWin *confwin = (ProfMucConfWin*)window;
|
||||
assert(confwin->memcheck == PROFCONFWIN_MEMCHECK);
|
||||
|
||||
ui_focus_win(window);
|
||||
ui_show_form(confwin);
|
||||
mucconfwin_show_form(confwin);
|
||||
|
||||
win_print(window, '-', 0, NULL, 0, 0, "", "");
|
||||
win_print(window, '-', 0, NULL, 0, 0, "", "Use '/form submit' to save changes.");
|
||||
@@ -100,7 +100,7 @@ ui_handle_room_configuration(const char *const roomjid, DataForm *form)
|
||||
}
|
||||
|
||||
void
|
||||
ui_show_form_field_help(ProfMucConfWin *confwin, char *tag)
|
||||
mucconfwin_field_help(ProfMucConfWin *confwin, char *tag)
|
||||
{
|
||||
ProfWin *window = (ProfWin*) confwin;
|
||||
FormField *field = form_get_field_by_tag(confwin->form, tag);
|
||||
@@ -181,7 +181,7 @@ ui_show_form_field_help(ProfMucConfWin *confwin, char *tag)
|
||||
}
|
||||
|
||||
void
|
||||
ui_show_form_help(ProfMucConfWin *confwin)
|
||||
mucconfwin_form_help(ProfMucConfWin *confwin)
|
||||
{
|
||||
if (confwin->form->instructions) {
|
||||
ProfWin *window = (ProfWin*) confwin;
|
||||
@@ -192,7 +192,7 @@ ui_show_form_help(ProfMucConfWin *confwin)
|
||||
}
|
||||
|
||||
static void
|
||||
_ui_handle_form_field(ProfWin *window, char *tag, FormField *field)
|
||||
_mucconfwin_form_field(ProfWin *window, char *tag, FormField *field)
|
||||
{
|
||||
win_vprint(window, '-', 0, NULL, NO_EOL, THEME_AWAY, "", "[%s] ", tag);
|
||||
win_vprint(window, '-', 0, NULL, NO_EOL | NO_DATE, 0, "", "%s", field->label);
|
||||
|
||||
10
src/ui/ui.h
10
src/ui/ui.h
@@ -108,14 +108,14 @@ void ui_handle_recipient_error(const char *const recipient, const char *const er
|
||||
void ui_handle_error(const char *const err_msg);
|
||||
void ui_clear_win_title(void);
|
||||
void ui_goodbye_title(void);
|
||||
void ui_handle_room_configuration(const char *const roomjid, DataForm *form);
|
||||
void mucconfwin_handle_configuration(const char *const roomjid, DataForm *form);
|
||||
void ui_handle_room_configuration_form_error(const char *const roomjid, const char *const message);
|
||||
void ui_handle_room_config_submit_result(const char *const roomjid);
|
||||
void ui_handle_room_config_submit_result_error(const char *const roomjid, const char *const message);
|
||||
void ui_show_form(ProfMucConfWin *confwin);
|
||||
void ui_show_form_field(ProfWin *window, DataForm *form, char *tag);
|
||||
void ui_show_form_help(ProfMucConfWin *confwin);
|
||||
void ui_show_form_field_help(ProfMucConfWin *confwin, char *tag);
|
||||
void mucconfwin_show_form(ProfMucConfWin *confwin);
|
||||
void mucconfwin_show_form_field(ProfWin *window, DataForm *form, char *tag);
|
||||
void mucconfwin_form_help(ProfMucConfWin *confwin);
|
||||
void mucconfwin_field_help(ProfMucConfWin *confwin, char *tag);
|
||||
void ui_show_lines(ProfWin *window, const gchar** lines);
|
||||
void ui_redraw_all_room_rosters(void);
|
||||
void ui_show_all_room_rosters(void);
|
||||
|
||||
Reference in New Issue
Block a user