Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(169)

Side by Side Diff: chromeos/geolocation/simple_geolocation_provider.cc

Issue 786693002: Move chrome/browser/chromeos/geolocation to chromeos/geolocation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add DEPS Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "chrome/browser/chromeos/geolocation/simple_geolocation_provider.h" 5 #include "chromeos/geolocation/simple_geolocation_provider.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <iterator> 8 #include <iterator>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
11 #include "base/time/time.h" 11 #include "base/time/time.h"
12 #include "chrome/browser/chromeos/geolocation/geoposition.h" 12 #include "chromeos/geolocation/geoposition.h"
13 #include "net/url_request/url_request_context_getter.h" 13 #include "net/url_request/url_request_context_getter.h"
14 #include "url/gurl.h" 14 #include "url/gurl.h"
15 15
16 namespace chromeos { 16 namespace chromeos {
17 17
18 namespace { 18 namespace {
19 const char kDefaultGeolocationProviderUrl[] = 19 const char kDefaultGeolocationProviderUrl[] =
20 "https://www.googleapis.com/geolocation/v1/geolocate?"; 20 "https://www.googleapis.com/geolocation/v1/geolocate?";
21 } // namespace 21 } // namespace
22 22
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 64
65 callback.Run(geoposition, server_error, elapsed); 65 callback.Run(geoposition, server_error, elapsed);
66 66
67 ScopedVector<SimpleGeolocationRequest>::iterator new_end = 67 ScopedVector<SimpleGeolocationRequest>::iterator new_end =
68 std::remove(requests_.begin(), requests_.end(), request); 68 std::remove(requests_.begin(), requests_.end(), request);
69 DCHECK_EQ(std::distance(new_end, requests_.end()), 1); 69 DCHECK_EQ(std::distance(new_end, requests_.end()), 1);
70 requests_.erase(new_end, requests_.end()); 70 requests_.erase(new_end, requests_.end());
71 } 71 }
72 72
73 } // namespace chromeos 73 } // namespace chromeos
OLDNEW
« no previous file with comments | « chromeos/geolocation/simple_geolocation_provider.h ('k') | chromeos/geolocation/simple_geolocation_request.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698