OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/browser/geolocation/geolocation_dispatcher_host.h" | 5 #include "content/browser/geolocation/geolocation_dispatcher_host.h" |
6 | 6 |
7 #include <map> | 7 #include <map> |
8 #include <set> | 8 #include <set> |
9 #include <utility> | 9 #include <utility> |
10 | 10 |
11 #include "base/bind.h" | 11 #include "base/bind.h" |
12 #include "content/browser/geolocation/geolocation_provider.h" | 12 #include "content/browser/geolocation/geolocation_provider.h" |
13 #include "content/browser/renderer_host/render_message_filter.h" | 13 #include "content/browser/renderer_host/render_message_filter.h" |
14 #include "content/browser/renderer_host/render_process_host_impl.h" | 14 #include "content/browser/renderer_host/render_process_host_impl.h" |
15 #include "content/browser/renderer_host/render_view_host_impl.h" | 15 #include "content/browser/renderer_host/render_view_host_impl.h" |
16 #include "content/public/browser/geolocation_permission_context.h" | 16 #include "content/public/browser/geolocation_permission_context.h" |
| 17 #include "content/public/common/geoposition.h" |
17 #include "content/common/geolocation_messages.h" | 18 #include "content/common/geolocation_messages.h" |
18 #include "content/common/geoposition.h" | |
19 | 19 |
20 using content::BrowserThread; | 20 using content::BrowserThread; |
21 using content::GeolocationPermissionContext; | 21 using content::GeolocationPermissionContext; |
| 22 using content::Geoposition; |
22 using content::RenderViewHostImpl; | 23 using content::RenderViewHostImpl; |
23 | 24 |
24 namespace { | 25 namespace { |
25 | 26 |
26 void NotifyArbitratorPermissionGranted() { | 27 void NotifyArbitratorPermissionGranted() { |
27 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); | 28 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
28 GeolocationProvider::GetInstance()->OnPermissionGranted(); | 29 GeolocationProvider::GetInstance()->OnPermissionGranted(); |
29 } | 30 } |
30 | 31 |
31 void SendGeolocationPermissionResponse(int render_process_id, | 32 void SendGeolocationPermissionResponse(int render_process_id, |
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
206 } | 207 } |
207 } // namespace | 208 } // namespace |
208 | 209 |
209 GeolocationDispatcherHost* GeolocationDispatcherHost::New( | 210 GeolocationDispatcherHost* GeolocationDispatcherHost::New( |
210 int render_process_id, | 211 int render_process_id, |
211 GeolocationPermissionContext* geolocation_permission_context) { | 212 GeolocationPermissionContext* geolocation_permission_context) { |
212 return new GeolocationDispatcherHostImpl( | 213 return new GeolocationDispatcherHostImpl( |
213 render_process_id, | 214 render_process_id, |
214 geolocation_permission_context); | 215 geolocation_permission_context); |
215 } | 216 } |
OLD | NEW |