[telepathy-doc/master] Fix linking of macros from Devhelp

Davyd Madeley davyd at madeley.id.au
Sun Apr 5 23:28:12 PDT 2009


---
 docs/book/insert-links.py |   10 +++++++---
 1 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/docs/book/insert-links.py b/docs/book/insert-links.py
index 6277e81..bc6cc60 100755
--- a/docs/book/insert-links.py
+++ b/docs/book/insert-links.py
@@ -71,9 +71,13 @@ class DevhelpMapper(object):
         return os.path.join(self.urlprefix, link)
 
     def _build_function_list(self, dom):
-        functions = self.xpath_query(dom,
-            'dh:functions/dh:keyword[@type = "function" or @type = "macro"]')
-        self.functions = self.build_map(functions, lambda n: n[:-3])
+        self.functions = self.build_map(
+            self.xpath_query(dom, type = 'function'),
+            lambda n: n[:-3])
+
+        self.functions.update (self.build_map(
+            self.xpath_query(dom, type = 'macro'),
+            lambda n: n[:-2]))
 
     def _build_class_list(self, dom):
         classes = self.xpath_query(dom, type = 'struct')
-- 
1.5.6.5




More information about the telepathy-commits mailing list