title: Cannot get my location to show up in Google Maps in iOS 8
body: <p>I'm trying to use the Google Maps for iOS in a Swift project for iOS 8. I added the Objective-C bridging header and added the Google Maps SDK as instructed in their <a href="https://developers.google.com/maps/documentation/ios/start" rel="nofollow noreferrer">documentation</a>. And I tried <a href="https://developers.google.com/maps/documentation/ios/start#add_a_map" rel="nofollow noreferrer">this</a> example and it works all fine.</p>
  
  <p>I needed to show my current location. I set coordinates for a Custom Location in my iOS 8 simulator and modified the code as shown in <a href="https://stackoverflow.com/a/20994202/1077789">this</a> StackOverflow answer. Below is the Swift version of it.</p>
  
  <pre><code>import UIKit
  import Foundation
  
  class MapViewController: UIViewController {
  
      @IBOutlet var mapView: GMSMapView!
  
      var firstLocationUpdate: Bool?
  
      override func viewDidLoad() {
          super.viewDidLoad()
  
          let camera = GMSCameraPosition.cameraWithLatitude(-33.86, longitude: 151.20, zoom: 12)
          mapView = GMSMapView.mapWithFrame(CGRectZero, camera: camera)
          mapView.settings.compassButton = true
          mapView.settings.myLocationButton = true
  
          mapView.addObserver(self, forKeyPath: "myLocation", options: .New, context: nil)
  
          dispatch_async(dispatch_get_main_queue(), { () -&gt; Void in
              self.mapView.myLocationEnabled = true
          })
          println(mapView.myLocation)
          view = mapView
  
          let marker = GMSMarker()
          marker.position = CLLocationCoordinate2DMake(-33.86, 151.20)
          marker.title = "Sydney"
          marker.snippet = "Australia"
          marker.map = mapView
      }
  
      override func observeValueForKeyPath(keyPath: String!, ofObject object: AnyObject!, change: [NSObject : AnyObject]!, context: UnsafeMutablePointer&lt;Void&gt;) {
          firstLocationUpdate = true
          let location = change[NSKeyValueChangeNewKey] as CLLocation
          mapView.camera = GMSCameraPosition.cameraWithTarget(location.coordinate, zoom: 14)
      }
  }
  </code></pre>
  
  <p>I ran it but it doesn't point to the location I assigned. When I <code>println()</code> out the location <code>println(mapView.myLocation)</code>, it returns <code>nil</code>.</p>
  
  <p>I assume this is because in iOS8, we explicitly have to ask the user to allow us to get their location. See <a href="https://stackoverflow.com/q/24062509/1077789">here</a>.</p>
  
  <p>I added the <code>NSLocationWhenInUseUsageDescription</code> key to my info.plist. My problem is how can I ask for the permission on <code>CLLocationManager</code> since I'm using Google Maps SDK. I put the below code just to check but it didn't prompt the permission dialog.</p>
  
  <pre><code>let locationManager = CLLocationManager()
  locationManager.requestWhenInUseAuthorization()
  </code></pre>
  
  <p>Is there a workaround this? Or do we have to wait until Google update their SDK?</p>
  
  <p>Thank you.</p>