tools/build_gtk_tree.js
authorAlan Knowles <alan@akbkhome.com>
Wed, 1 Dec 2010 09:11:08 +0000 (17:11 +0800)
committerAlan Knowles <alan@akbkhome.com>
Wed, 1 Dec 2010 09:11:08 +0000 (17:11 +0800)
tools/build_gtk_tree.js

index dfe698b..d2cb26e 100644 (file)
@@ -51,12 +51,29 @@ ns_list.forEach(function(ns_name) {
 print("Looping throught namespaces");
 var ns_idx = [];
 var implementations = {};
-
+var methods = {}
+   
 for (cls in classes) {
     var odata = classes[cls];
+    methods[cls] = {}
+       
     implementations[odata.alias] = odata.titleType == 'Class' ? odata.childClasses :  odata.implementedBy;  
     print(JSON.stringify(odata.methods,null,4));
-    
+    odata.methods.forEach(function(m) {
+       
+        m.params.forEach(function(p) {
+             
+            if (!p.type || typeof(classes[p.type]) == 'undefined') {
+                return;
+            }
+            if (typeof(methods[cls][p.type]) == 'undefined') {
+                methods[cls][p.type] = [];
+            }
+            methods[cls][p.type].push(
+            
+        }
+        
+    }
     //for(method in odata.methods) {
     //    print(method.name);
     //}