     
     var tree = [TreeElement]()
     var views = [UIView]()
-    
+    var viewsToDisplay = [UIView]() {
+        didSet {
+            buildTreeForNodeCount(viewsToDisplay.count)
+            updateViews()
+        }
+    }
     
     
     

    
    
    func setGridViews(views: [UIView]) {
        for view in views {
            rootNode.addArrangedSubview(view)
        }
    }
    
    




/*
//MARK: - Class
*/
