     private func removeCurrentChild() {
         
         self.currentChildView?.removeFromSuperview()
+        self.currentChildView = nil
+        
         self.currentChildViewController?.removeFromParentViewController()
+        self.currentChildViewController = nil
         
     }
     
     private func configureNewChildView(child: ChildViewController) {
         
+        self.currentChildViewController = child
         self.currentChildView = child.view
+        
         self.currentChildView!.layer.zPosition = 2.0
-        
-        self.currentChildViewController = child
         
         child.view.frame = childViewFrame
         self.addChildViewController(child)

    
    private func configureSettingsViewWithNewChild(child: ChildViewController) {
        
        
        
    }
    

         [2]
            
        */
        case self.selectScreenTableView: return
        case self.settingsScreenTableView: func nothing(){}; nothing()  // don't do anything here
        default: return
            
        }
        
    }

}


// MARK: BarViewDelegate
extension ViewController: UITableViewDataSource {

    func tableView(tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
        
        // respond differently based on the tableview
        switch tableView {
            
        case self.selectScreenTableView:
            return 0
            
        case self.settingsScreenTableView:
            
            if let title = self.currentChildViewController?.title,
                let configEntriesForCurrentChildVC = self.configDictionaries[title] {
                    
                    return configEntriesForCurrentChildVC.count
                    
            } else {
                
                return 0
                
            }
            
        default: return 0
            
        }
        
    }
    
    func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell {
        
        func nothing(){}
        
        // respond differently based on the tableview
        switch tableView {
            
        case self.selectScreenTableView: nothing()
        case self.settingsScreenTableView: nothing()
        default: nothing()
            
        }
        
        return UITableViewCell()
        
    }

}
