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

Issue 2126893003: Geolocation cleanup: make GeolocationDelegate::OverrideSystemLocationProvider return unique_ptr (Closed)

Created:
4 years, 5 months ago by mcasas
Modified:
4 years, 5 months ago
Reviewers:
ncarter (slow), ostap, Wez, CJ
CC:
chromium-reviews, anandc+watch-blimp_chromium.org, maniscalco+watch-blimp_chromium.org, sriramsr+watch-blimp_chromium.org, mlamouri+watch-geolocation_chromium.org, jam, nyquist+watch-blimp_chromium.org, marcinjb+watch-blimp_chromium.org, jessicag+watch-blimp_chromium.org, kmarshall+watch-blimp_chromium.org, lethalantidote+watch-blimp_chromium.org, Michael van Ouwerkerk, darin-cc_chromium.org, dtrainor+watch-blimp_chromium.org, shaktisahu+watch-blimp_chromium.org, khushalsagar+watch-blimp_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Geolocation cleanup: make GeolocationDelegate::OverrideSystemLocationProvider return unique_ptr This CL changes the signature of GeolocationDelegate's virtual LocationProvider* OverrideSystemLocationProvider(); to virtual std::unique_ptr<LocationProvider> OverrideSystemLocationProvider(); Most of the code changes are trivial except in the unittests where the lifetime of the generated LocationProvider needs to be taken into account. BUG=623132 TEST=all relevant unittests and browser_tests working, in particular ./out/gn/browser_tests --gtest_filter="GeolocationBrowserTest.*" ./out/gn/content_unittests --gtest_filter="GeolocationLocationArbitratorTest.* CQ_INCLUDE_TRYBOTS=tryserver.chromium.linux:linux_site_isolation Committed: https://crrev.com/f6da183fd9aa098f57e04f55c589db3eb31786f5 Cr-Commit-Position: refs/heads/master@{#404693}

Patch Set 1 #

Patch Set 2 : #

Total comments: 13

Patch Set 3 : wez@s comments #

Total comments: 3

Patch Set 4 : wez@ comments; refactored GeolocationLocationArbitratorTest and TestingLocationArbitrator #

Total comments: 6

Patch Set 5 : wez@ comments (InitializeArbitrator(), removed hacks) #

Total comments: 2

Patch Set 6 : wez@ nit #

Unified diffs Side-by-side diffs Delta from patch set Stats (+62 lines, -83 lines) Patch
M blimp/engine/app/blimp_content_browser_client.cc View 1 1 chunk +3 lines, -6 lines 0 comments Download
M content/browser/geolocation/location_arbitrator_impl.h View 1 2 3 1 chunk +2 lines, -2 lines 0 comments Download
M content/browser/geolocation/location_arbitrator_impl.cc View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/geolocation/location_arbitrator_impl_unittest.cc View 1 2 3 4 5 12 chunks +44 lines, -66 lines 0 comments Download
M content/public/browser/geolocation_delegate.h View 1 2 3 4 1 chunk +9 lines, -7 lines 0 comments Download
M content/public/browser/geolocation_delegate.cc View 2 chunks +3 lines, -1 line 0 comments Download

Messages

Total messages: 27 (9 generated)
mcasas
lethalantidote@/wez@ PTAL sl.ostapenko@samsung.com: FYI/PTAL -- note that this CL changes a method signature, potentially breaking ...
4 years, 5 months ago (2016-07-07 00:35:19 UTC) #3
Wez
nit: Re the CL description "which was a cleanup-todo" seems redundant :P It's also not ...
4 years, 5 months ago (2016-07-07 18:34:06 UTC) #4
mcasas
On 2016/07/07 18:34:06, Wez wrote: > nit: Re the CL description "which was a cleanup-todo" ...
4 years, 5 months ago (2016-07-07 18:38:38 UTC) #6
Wez
https://codereview.chromium.org/2126893003/diff/20001/blimp/engine/app/blimp_content_browser_client.cc File blimp/engine/app/blimp_content_browser_client.cc (left): https://codereview.chromium.org/2126893003/diff/20001/blimp/engine/app/blimp_content_browser_client.cc#oldcode31 blimp/engine/app/blimp_content_browser_client.cc:31: std::unique_ptr<BlimpLocationProvider> location_provider_; You're changing the ownership semantics here - ...
4 years, 5 months ago (2016-07-07 18:51:39 UTC) #7
mcasas
https://codereview.chromium.org/2126893003/diff/20001/blimp/engine/app/blimp_content_browser_client.cc File blimp/engine/app/blimp_content_browser_client.cc (left): https://codereview.chromium.org/2126893003/diff/20001/blimp/engine/app/blimp_content_browser_client.cc#oldcode31 blimp/engine/app/blimp_content_browser_client.cc:31: std::unique_ptr<BlimpLocationProvider> location_provider_; On 2016/07/07 18:51:39, Wez wrote: > You're ...
4 years, 5 months ago (2016-07-07 19:07:09 UTC) #8
Wez
https://codereview.chromium.org/2126893003/diff/20001/content/browser/geolocation/location_arbitrator_impl_unittest.cc File content/browser/geolocation/location_arbitrator_impl_unittest.cc (right): https://codereview.chromium.org/2126893003/diff/20001/content/browser/geolocation/location_arbitrator_impl_unittest.cc#newcode134 content/browser/geolocation/location_arbitrator_impl_unittest.cc:134: return GetFakeGeolocationDelegate()->system_location_provider(); On 2016/07/07 19:07:09, mcasas wrote: > On ...
4 years, 5 months ago (2016-07-07 21:47:10 UTC) #9
mcasas
PTAL https://codereview.chromium.org/2126893003/diff/20001/content/browser/geolocation/location_arbitrator_impl_unittest.cc File content/browser/geolocation/location_arbitrator_impl_unittest.cc (right): https://codereview.chromium.org/2126893003/diff/20001/content/browser/geolocation/location_arbitrator_impl_unittest.cc#newcode134 content/browser/geolocation/location_arbitrator_impl_unittest.cc:134: return GetFakeGeolocationDelegate()->system_location_provider(); On 2016/07/07 21:47:10, Wez wrote: > ...
4 years, 5 months ago (2016-07-07 23:58:42 UTC) #12
CJ
lgtm
4 years, 5 months ago (2016-07-08 19:00:33 UTC) #13
mcasas
nick@ can you please RS? (pending wez@s LGTM)
4 years, 5 months ago (2016-07-08 22:13:56 UTC) #15
ncarter (slow)
content lgtm
4 years, 5 months ago (2016-07-08 22:20:06 UTC) #16
Wez
https://codereview.chromium.org/2126893003/diff/40001/content/browser/geolocation/location_arbitrator_impl_unittest.cc File content/browser/geolocation/location_arbitrator_impl_unittest.cc (right): https://codereview.chromium.org/2126893003/diff/40001/content/browser/geolocation/location_arbitrator_impl_unittest.cc#newcode128 content/browser/geolocation/location_arbitrator_impl_unittest.cc:128: DCHECK(is_fake_delegate_); You don't want to remove this, otherwise someone ...
4 years, 5 months ago (2016-07-08 23:12:58 UTC) #17
mcasas
wez@ PTAL https://codereview.chromium.org/2126893003/diff/80001/content/browser/geolocation/location_arbitrator_impl_unittest.cc File content/browser/geolocation/location_arbitrator_impl_unittest.cc (right): https://codereview.chromium.org/2126893003/diff/80001/content/browser/geolocation/location_arbitrator_impl_unittest.cc#newcode126 content/browser/geolocation/location_arbitrator_impl_unittest.cc:126: return static_cast<MockLocationProvider*>(providers_.front().get()); On 2016/07/08 23:12:57, Wez wrote: ...
4 years, 5 months ago (2016-07-09 01:24:18 UTC) #18
Wez
lgtm https://codereview.chromium.org/2126893003/diff/100001/content/browser/geolocation/location_arbitrator_impl_unittest.cc File content/browser/geolocation/location_arbitrator_impl_unittest.cc (right): https://codereview.chromium.org/2126893003/diff/100001/content/browser/geolocation/location_arbitrator_impl_unittest.cc#newcode78 content/browser/geolocation/location_arbitrator_impl_unittest.cc:78: mock_location_provider_ = new MockLocationProvider; Looks like you want ...
4 years, 5 months ago (2016-07-11 17:10:11 UTC) #19
mcasas
https://codereview.chromium.org/2126893003/diff/100001/content/browser/geolocation/location_arbitrator_impl_unittest.cc File content/browser/geolocation/location_arbitrator_impl_unittest.cc (right): https://codereview.chromium.org/2126893003/diff/100001/content/browser/geolocation/location_arbitrator_impl_unittest.cc#newcode78 content/browser/geolocation/location_arbitrator_impl_unittest.cc:78: mock_location_provider_ = new MockLocationProvider; On 2016/07/11 17:10:10, Wez wrote: ...
4 years, 5 months ago (2016-07-11 17:18:19 UTC) #20
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2126893003/120001
4 years, 5 months ago (2016-07-11 17:37:41 UTC) #23
commit-bot: I haz the power
Committed patchset #6 (id:120001)
4 years, 5 months ago (2016-07-11 18:28:24 UTC) #24
commit-bot: I haz the power
CQ bit was unchecked.
4 years, 5 months ago (2016-07-11 18:28:38 UTC) #25
commit-bot: I haz the power
4 years, 5 months ago (2016-07-11 18:32:41 UTC) #27
Message was sent while issue was closed.
Patchset 6 (id:??) landed as
https://crrev.com/f6da183fd9aa098f57e04f55c589db3eb31786f5
Cr-Commit-Position: refs/heads/master@{#404693}

Powered by Google App Engine
This is Rietveld 408576698