summaryrefslogtreecommitdiff
path: root/src/fe-text/statusbar-config.c
diff options
context:
space:
mode:
authorAilin Nemui <ailin@esf51.localdomain>2015-01-07 03:40:34 +0100
committerAilin Nemui <ailin@linux.site>2015-02-17 09:50:55 +0100
commit96d4fb9156bcef6fc14dbec43dfa0fcd0226d46f (patch)
tree27a1023f98d6a1b908fc4ce65995723cc5c56746 /src/fe-text/statusbar-config.c
parent6b08cbe906bc2f13a34aca3195f8808d709c160c (diff)
downloadirssi-96d4fb9156bcef6fc14dbec43dfa0fcd0226d46f.zip
add CONFIG_REC to config_node_section* APIs
this adds the CONFIG_REC * to the config_node_section and config_node_section_index APIs as they will require access to the config cache later on to make the config parser more robust.
Diffstat (limited to 'src/fe-text/statusbar-config.c')
-rw-r--r--src/fe-text/statusbar-config.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/fe-text/statusbar-config.c b/src/fe-text/statusbar-config.c
index deaa1b5d..e8943dac 100644
--- a/src/fe-text/statusbar-config.c
+++ b/src/fe-text/statusbar-config.c
@@ -177,7 +177,7 @@ static void statusbar_read(STATUSBAR_GROUP_REC *group, CONFIG_NODE *node)
bar->placement = STATUSBAR_TOP;
bar->position = config_node_get_int(node, "position", 0);
- node = config_node_section(node, "items", -1);
+ node = iconfig_node_section(node, "items", -1);
if (node != NULL) {
/* we're overriding the items - destroy the old */
while (bar->items != NULL)
@@ -227,7 +227,7 @@ static void read_statusbar_config_from_node(CONFIG_NODE *node)
CONFIG_NODE *items;
GSList *tmp;
- items = config_node_section(node, "items", -1);
+ items = iconfig_node_section(node, "items", -1);
if (items != NULL)
statusbar_read_items(items);
@@ -369,7 +369,7 @@ static void cmd_statusbar_reset(const char *data, void *server,
CONFIG_NODE *parent;
parent = iconfig_node_traverse("statusbar", TRUE);
- parent = config_node_section(parent, active_statusbar_group->name,
+ parent = iconfig_node_section(parent, active_statusbar_group->name,
NODE_TYPE_BLOCK);
iconfig_node_set_str(parent, node->key, NULL);
@@ -432,7 +432,7 @@ static CONFIG_NODE *statusbar_items_section(CONFIG_NODE *parent)
CONFIG_NODE *node;
GSList *tmp;
- node = config_node_section(parent, "items", -1);
+ node = iconfig_node_section(parent, "items", -1);
if (node != NULL)
return node;
@@ -446,11 +446,11 @@ static CONFIG_NODE *statusbar_items_section(CONFIG_NODE *parent)
/* since items list in config file overrides defaults,
we'll need to copy the whole list. */
- parent = config_node_section(parent, "items", NODE_TYPE_BLOCK);
+ parent = iconfig_node_section(parent, "items", NODE_TYPE_BLOCK);
for (tmp = bar->items; tmp != NULL; tmp = tmp->next) {
SBAR_ITEM_CONFIG_REC *rec = tmp->data;
- node = config_node_section(parent, rec->name,
+ node = iconfig_node_section(parent, rec->name,
NODE_TYPE_BLOCK);
if (rec->priority != 0)
iconfig_node_set_int(node, "priority", rec->priority);
@@ -487,7 +487,7 @@ static void cmd_statusbar_add(const char *data, void *server,
if (value != NULL) index = config_node_index(node, value)+1;
/* create/move item */
- node = config_node_section_index(node, name, index, NODE_TYPE_BLOCK);
+ node = iconfig_node_section_index(node, name, index, NODE_TYPE_BLOCK);
/* set the options */
value = g_hash_table_lookup(optlist, "priority");
@@ -511,7 +511,7 @@ static void cmd_statusbar_remove(const char *data, void *server,
if (node == NULL)
return;
- if (config_node_section(node, data, -1) != NULL)
+ if (iconfig_node_section(node, data, -1) != NULL)
iconfig_node_set_str(node, data, NULL);
else {
printformat(NULL, NULL, MSGLEVEL_CLIENTERROR,
@@ -545,9 +545,9 @@ static void cmd_statusbar(const char *data)
/* lookup/create the statusbar node */
node = iconfig_node_traverse("statusbar", TRUE);
- node = config_node_section(node, active_statusbar_group->name,
+ node = iconfig_node_section(node, active_statusbar_group->name,
NODE_TYPE_BLOCK);
- node = config_node_section(node, name, NODE_TYPE_BLOCK);
+ node = iconfig_node_section(node, name, NODE_TYPE_BLOCK);
/* call the subcommand */
signal = g_strconcat("command statusbar ", cmd, NULL);