RooRepo.vala
[gitlive] / RooRepo.vala
index 987bab6..d7bf4f4 100644 (file)
@@ -5,7 +5,7 @@ static RooRepo _RooRepo ;
 public class RooRepo : Object 
 {
  
-       
+       const string roourl = "https://roojs.com/admin.php/Roo";  
 
        public string  id; // not really important that they are numbers..
        public string project_id;
@@ -23,11 +23,13 @@ public class RooRepo : Object
        }
        
        static Gee.ArrayList<RooRepo> _repos; // only available for singletonn.         
-       static public  Gee.ArrayList<RooRepo>() {
+       static int loadcount = 0;
+       public static  Gee.ArrayList<RooRepo> repos() {
                RooRepo.init();
                return RooRepo._repos;
        }
-       public RooRepo add(Json.Object t)
+       
+       static RooRepo add(Json.Object t)
        {
                var add = new RooRepo();
                add.id = t.get_string_member("id");
@@ -82,9 +84,9 @@ public class RooRepo : Object
                        var rd = response.get_array_member ("data");
                        
                        // got a valid result...
-                       var _this = RooTicket.singleton();
                        for(var i = 0; i < rd.get_length(); i++) {
-                               _this.addRepo(rd.get_object_element(i));
+                               RooRepo.add(rd.get_object_element(i));
                        }