summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMikael Hallendal <micke@codefactory.se>2002-03-03 17:16:44 +0000
committerMikael Hallendal <hallski@src.gnome.org>2002-03-03 17:16:44 +0000
commit585fdc6d109cbc87ebd64488722c8b07142865da (patch)
tree8af6b08175b5ba1707125c6e6c00a12257a0ec79
parent2bcc93ab7dcb30724c40f6ad3233a461465606ab (diff)
downloadyelp-585fdc6d109cbc87ebd64488722c8b07142865da.tar.gz
boooring.
2002-03-03 Mikael Hallendal <micke@codefactory.se> * src/yelp-index-model.c: use the new YELP_SECTION-macro. * src/yelp-view-toc.c: same. * src/yelp-util.c: same. * src/yelp-scrollkeeper.c: same.
-rw-r--r--ChangeLog5
-rw-r--r--src/yelp-index-model.c4
-rw-r--r--src/yelp-scrollkeeper.c2
-rw-r--r--src/yelp-util.c4
-rw-r--r--src/yelp-view-toc.c6
5 files changed, 13 insertions, 8 deletions
diff --git a/ChangeLog b/ChangeLog
index e28b75a0..d4134e5a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
2002-03-03 Mikael Hallendal <micke@codefactory.se>
+ * src/yelp-index-model.c: use the new YELP_SECTION-macro.
+ * src/yelp-view-toc.c: same.
+ * src/yelp-util.c: same.
+ * src/yelp-scrollkeeper.c: same.
+
* src/yelp-section.h: added casting macro YELP_SECTION.
* src/yelp-base.c (yelp_base_new): pass index-list to info init.
diff --git a/src/yelp-index-model.c b/src/yelp-index-model.c
index e9af0bfe..205b6664 100644
--- a/src/yelp-index-model.c
+++ b/src/yelp-index-model.c
@@ -271,7 +271,7 @@ yim_get_value (GtkTreeModel *tree_model,
g_return_if_fail (YELP_IS_INDEX_MODEL (tree_model));
g_return_if_fail (iter != NULL);
- section = (YelpSection *) (G_LIST(iter->user_data)->data);
+ section = YELP_SECTION (G_LIST(iter->user_data)->data);
switch (column) {
case YELP_INDEX_MODEL_COL_NAME:
@@ -460,7 +460,7 @@ yelp_index_model_filter (YelpIndexModel *model, const gchar *string)
new_list = priv->original_list;
} else {
for (node = priv->original_list; node; node = node->next) {
- section = (YelpSection *) node->data;
+ section = YELP_SECTION (node->data);
if (!strncmp (section->name, string, strlen (string))) {
/* Include in the new list */
diff --git a/src/yelp-scrollkeeper.c b/src/yelp-scrollkeeper.c
index bc39b8cf..6613722c 100644
--- a/src/yelp-scrollkeeper.c
+++ b/src/yelp-scrollkeeper.c
@@ -407,7 +407,7 @@ ys_parse_index (GList **index)
index_dir,
file_info->name);
- section = (YelpSection *) node->data;
+ section = YELP_SECTION (node->data);
ys_parse_index_file (index, index_path, section);
diff --git a/src/yelp-util.c b/src/yelp-util.c
index 42893a46..eb840c87 100644
--- a/src/yelp-util.c
+++ b/src/yelp-util.c
@@ -425,7 +425,7 @@ yelp_util_find_toplevel (GNode *doc_tree,
node = g_node_first_child (doc_tree);
while (node) {
- section = (YelpSection *) node->data;
+ section = YELP_SECTION (node->data);
if (!strcmp (name, section->name)) {
return node;
@@ -443,7 +443,7 @@ tree_find_node (GNode *node, const gchar *uri)
{
YelpSection *section;
- section = (YelpSection *) node->data;
+ section = YELP_SECTION (node->data);
if (!section || !section->uri) {
return FALSE;
diff --git a/src/yelp-view-toc.c b/src/yelp-view-toc.c
index e1ad2a49..5789a5b0 100644
--- a/src/yelp-view-toc.c
+++ b/src/yelp-view-toc.c
@@ -354,7 +354,7 @@ yelp_view_toc_start (YelpViewTOC *view)
node = g_node_first_child (root);
while (node) {
- section = (YelpSection *) node->data;
+ section = YELP_SECTION (node->data);
path = yelp_util_node_to_string_path (node);
yelp_view_toc_printf (view,
"<a href=\"toc:scrollkeeper/%s\">%s</a><br>\n",
@@ -556,7 +556,7 @@ yelp_view_toc_man_1 (YelpViewTOC *view)
child = g_node_first_child (node);
if (child) {
- section = (YelpSection *) node->data;
+ section = YELP_SECTION (node->data);
path = yelp_util_node_to_string_path (node);
yelp_view_toc_printf (view,
"<a href=\"toc:man/%s\">%s</a><br>\n",
@@ -600,7 +600,7 @@ yelp_view_toc_info (YelpViewTOC *view)
yelp_view_toc_printf (view, "<h1>%s</h1>\n", string);
do {
- section = (YelpSection *) node->data;
+ section = YELP_SECTION (node->data);
url = yelp_util_compose_path_url (root, section->uri);
yelp_view_toc_printf (view,
"<a href=\"%s\">%s</a><br>\n",