     }
     
     @IBAction func lookUpButtonTabbed(sender: AnyObject) {
-//        if tableView.hidden {
-//            tableView.hidden = false;
-//        }
-//        else {
-//            tableView.hidden = true;
-//        }
-
-//        tableView.selectRowAtIndexPath(NSIndexPath(forRow: 1, inSection: 2), animated: true,scrollPosition: UITableViewScrollPosition.Middle);
-//        tableView(tableView, didSelectRowAtIndexPath: NSIndexPath(forRow: 1, inSection: 2));
-        
-    }
-   
+        //        if tableView.hidden {
+        //            tableView.hidden = false;
+        //        }
+        //        else {
+        //            tableView.hidden = true;
+        //        }
+        
+        //        tableView.selectRowAtIndexPath(NSIndexPath(forRow: 1, inSection: 2), animated: true,scrollPosition: UITableViewScrollPosition.Middle);
+        //        tableView(tableView, didSelectRowAtIndexPath: NSIndexPath(forRow: 1, inSection: 2));
+        
+    }
+    
     @IBAction func focusItemTabbed(sender: AnyObject) {
-        
         focusToggle.setOn(!focusToggle.on, animated: true)
     }
     

        
    }
    
    func selectOnMap(geoBaseEntityToSelect : GeoBaseEntity?){
        if  highlightedLine != nil {
            mapView.removeOverlay(highlightedLine);
        }
        let selectedAnnotations = mapView.selectedAnnotations
        if selectedAnnotations != nil {
            for selAnno in selectedAnnotations{
                if let a = (selAnno as? MKAnnotation){
                    mapView.deselectAnnotation(a, animated: true)
                }
                
            }
        }
        
        if let geoBaseEntity = geoBaseEntityToSelect{
            var mapObj=geoBaseEntity.mapObject
            
            if mapObj is GeoBaseEntityPointAnnotation {
                mapView.selectAnnotation(mapObj as MKAnnotation, animated: true);
                //println("\((mapObj as GeoBaseEntityPointAnnotation).coordinate.latitude),\((mapObj as GeoBaseEntityPointAnnotation).coordinate.longitude)")
            }
            else if mapObj is GeoBaseEntityStyledMkPolylineAnnotation {
                var line = mapObj as GeoBaseEntityStyledMkPolylineAnnotation;
                highlightedLine = HighlightedMkPolyline(points: line.points(), count: line.pointCount);
                mapView.removeOverlay(line);
                mapView.addOverlay(highlightedLine);
                mapView.addOverlay(line);
                
                
                
            }
            
            
            if geoBaseEntity is Leuchte {
                
            } else if geoBaseEntity is Leitung {
                for i in 0...searchResults[LEITUNGEN].count-1 {
                    var leuchten : [GeoBaseEntity] = searchResults[LEITUNGEN]
                    if leuchten[i].id == geoBaseEntity.id {
                        tableView.selectRowAtIndexPath(NSIndexPath(forRow: i, inSection: LEITUNGEN), animated: true, scrollPosition: UITableViewScrollPosition.Top)
                        break;
                    }
                }
            } else if geoBaseEntity is Mauerlasche {
                
            }
        }
        
        
        
    }
    

}

    
    
    func mapView(mapView: MKMapView!, regionDidChangeAnimated animated: Bool) {
        //        println(mapView.region.span.latitudeDelta);
    }
    
    func mapView(mapView: MKMapView!, viewForAnnotation annotation: MKAnnotation!) -> MKAnnotationView! {
