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

Issue 11312210: Do not send stale position in GeolocationProvider::AddObserver. (Closed)

Created:
8 years, 1 month ago by John Knottenbelt
Modified:
8 years ago
Reviewers:
joth, bulach
CC:
chromium-reviews, joi+watch-content_chromium.org, darin-cc_chromium.org, jam, vadimt
Visibility:
Public.

Description

Do not stale cached position in GeolocationProvider::AddObserver. WebKit is expecting a fresh geolocation positions from the GeolocationClient, so we should try to send a fresh geolocation position. TEST= BUG=157244 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=170806

Patch Set 1 #

Total comments: 1

Patch Set 2 : Clear cached position when last observer unsubscribes. #

Patch Set 3 : Add a test. #

Total comments: 2

Patch Set 4 : Make suggested changes. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+62 lines, -0 lines) Patch
M content/browser/geolocation/geolocation_provider.cc View 1 2 1 chunk +3 lines, -0 lines 0 comments Download
M content/browser/geolocation/geolocation_provider_unittest.cc View 1 2 3 4 chunks +59 lines, -0 lines 0 comments Download

Messages

Total messages: 16 (0 generated)
John Knottenbelt
Hi Marcus, Joth, Comments much appreciated. I'm wondering about tests for this, too. I think ...
8 years, 1 month ago (2012-11-13 14:36:14 UTC) #1
joth
On 13 November 2012 14:36, <jknotten@chromium.org> wrote: > Reviewers: joth, bulach, > > Message: > ...
8 years, 1 month ago (2012-11-13 18:53:21 UTC) #2
John Knottenbelt
I agree. I would prefer not to have this section in there at all, and ...
8 years, 1 month ago (2012-11-13 18:58:17 UTC) #3
bulach
hmm... if i remember the flow correctly, it's something like: GeolocationProvider::AddObserver GeolocationProvider::OnClientsChanged GeolocationProvider::AddObserver GeolocationProvider::StartProviders LocationArbitrator::StartProviders ...
8 years, 1 month ago (2012-11-13 19:22:27 UTC) #4
John Knottenbelt
You're right. If I have a second tab with a geolocation watch, it causes the ...
8 years, 1 month ago (2012-11-14 15:56:26 UTC) #5
John Knottenbelt
https://codereview.chromium.org/11312210/diff/1/content/browser/geolocation/geolocation_provider.cc File content/browser/geolocation/geolocation_provider.cc (right): https://codereview.chromium.org/11312210/diff/1/content/browser/geolocation/geolocation_provider.cc#newcode29 content/browser/geolocation/geolocation_provider.cc:29: observer->OnLocationUpdate(position_); We don't want to send this if we're ...
8 years, 1 month ago (2012-11-18 16:03:07 UTC) #6
vadimt
I’ve tried the patch, and found a strange behavior. Repro: I have Windows 7, with ...
8 years, 1 month ago (2012-11-21 23:25:23 UTC) #7
John Knottenbelt
Thanks for testing, Vadim! As you've observed, this patch isn't the whole story regarding freshness ...
8 years, 1 month ago (2012-11-22 10:39:54 UTC) #8
John Knottenbelt
This patch adds the test.
8 years ago (2012-11-30 16:24:16 UTC) #9
bulach
lgtm, thanks! I have one suggestion for the test, please let me know your thoughts: ...
8 years ago (2012-11-30 16:49:56 UTC) #10
John Knottenbelt
Thanks for reviewing, Marcus! I've made the suggested change, but used RunUntilIdle() as I believe ...
8 years ago (2012-11-30 17:25:19 UTC) #11
John Knottenbelt
Publish draft comment, suggested change made in patch set 4. https://codereview.chromium.org/11312210/diff/20001/content/browser/geolocation/geolocation_provider_unittest.cc File content/browser/geolocation/geolocation_provider_unittest.cc (right): https://codereview.chromium.org/11312210/diff/20001/content/browser/geolocation/geolocation_provider_unittest.cc#newcode220 ...
8 years ago (2012-11-30 17:26:47 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jknotten@chromium.org/11312210/22006
8 years ago (2012-12-03 17:06:21 UTC) #13
commit-bot: I haz the power
Retried try job too often on linux_rel for step(s) ash_unittests
8 years ago (2012-12-03 18:14:04 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jknotten@chromium.org/11312210/22006
8 years ago (2012-12-03 18:47:40 UTC) #15
commit-bot: I haz the power
8 years ago (2012-12-03 20:54:57 UTC) #16
Message was sent while issue was closed.
Change committed as 170806

Powered by Google App Engine
This is Rietveld 408576698