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

Issue 273523007: Dispatch geolocation IPCs on the UI thread. Aside from simplifying the code to avoid a lot of threa… (Closed)

Created:
6 years, 7 months ago by jam
Modified:
6 years, 7 months ago
CC:
chromium-reviews, nkostylev+watch_chromium.org, nasko+codewatch_chromium.org, browser-components-watch_chromium.org, stevenjb+watch_chromium.org, miu+watch_chromium.org, extensions-reviews_chromium.org, benquan, Ilya Sherman, jam, darin-cc_chromium.org, jochen+watch_chromium.org, chromium-apps-reviews_chromium.org, erikwright+watch_chromium.org, android-webview-reviews_chromium.org, creis+watch_chromium.org, oshima+watch_chromium.org, rouslan+autofillwatch_chromium.org, Dane Wallinga, dyu1, estade+watch_chromium.org, davemoore+watch_chromium.org, site-isolation-reviews_chromium.org
Visibility:
Public.

Description

Dispatch geolocation IPCs on the UI thread. Aside from simplifying the code to avoid a lot of thread hops, this sets things up for converting the code to work on RenderFrames instead of RenderViews. In the process I also switched the code to use CallbackList which simplifies the registration. BUG=304341 R=benm@chromium.org, brettw@chromium.org, bulach@chromium.org, caitkp@chromium.org, isherman@chromium.org, mvanouwerkerk@chromium.org, nasko@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=269795

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : sync #

Patch Set 4 : fix android #

Total comments: 17

Patch Set 5 : review comments #

Patch Set 6 : fix browser_tests #

Patch Set 7 : benm comments #

Total comments: 12

Patch Set 8 : refix android because of moved header #

Patch Set 9 : review comments #

Total comments: 3

Patch Set 10 : sync #

Patch Set 11 : sync #

Patch Set 12 : sync #

Total comments: 2

Patch Set 13 : update per cait #

Patch Set 14 : fix android merge problem #

Patch Set 15 : sync #

Unified diffs Side-by-side diffs Delta from patch set Stats (+363 lines, -795 lines) Patch
M android_webview/native/aw_contents.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +1 line, -1 line 0 comments Download
M android_webview/native/aw_geolocation_permission_context.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +2 lines, -17 lines 0 comments Download
M android_webview/native/aw_geolocation_permission_context.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +6 lines, -56 lines 0 comments Download
M base/callback_list.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 3 chunks +26 lines, -4 lines 0 comments Download
M base/callback_list.h.pump View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 3 chunks +26 lines, -4 lines 0 comments Download
M chrome/browser/chromeos/policy/device_status_collector.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 4 chunks +4 lines, -29 lines 0 comments Download
M chrome/browser/chromeos/policy/device_status_collector.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 3 chunks +13 lines, -55 lines 0 comments Download
M chrome/browser/extensions/api/location/location_manager.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +1 line, -3 lines 0 comments Download
M chrome/browser/extensions/api/location/location_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 7 chunks +21 lines, -75 lines 0 comments Download
M chrome/browser/geolocation/chrome_geolocation_permission_context.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +2 lines, -4 lines 0 comments Download
M chrome/browser/geolocation/chrome_geolocation_permission_context.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 5 chunks +8 lines, -35 lines 0 comments Download
M chrome/browser/geolocation/chrome_geolocation_permission_context_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 19 chunks +39 lines, -29 lines 0 comments Download
M chrome/browser/guest_view/web_view/web_view_guest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +1 line, -2 lines 0 comments Download
M chrome/browser/ui/autofill/autofill_dialog_controller_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +1 line, -11 lines 0 comments Download
M chrome/test/base/ui_test_utils.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +2 lines, -7 lines 0 comments Download
M components/autofill/content/browser/risk/fingerprint.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 4 chunks +10 lines, -74 lines 0 comments Download
M components/autofill/content/browser/risk/fingerprint_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +2 lines, -5 lines 0 comments Download
M content/browser/android/content_view_core_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +0 lines, -3 lines 0 comments Download
M content/browser/android/content_view_core_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 4 chunks +2 lines, -20 lines 0 comments Download
M content/browser/geolocation/geolocation_dispatcher_host.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +23 lines, -52 lines 0 comments Download
M content/browser/geolocation/geolocation_dispatcher_host.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 4 chunks +56 lines, -120 lines 0 comments Download
M content/browser/geolocation/geolocation_provider_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 4 chunks +11 lines, -26 lines 0 comments Download
M content/browser/geolocation/geolocation_provider_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 6 chunks +32 lines, -89 lines 0 comments Download
M content/browser/geolocation/geolocation_provider_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 7 chunks +22 lines, -13 lines 0 comments Download
M content/browser/renderer_host/render_process_host_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 4 chunks +0 lines, -10 lines 0 comments Download
M content/browser/renderer_host/render_process_host_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 4 chunks +0 lines, -6 lines 0 comments Download
M content/browser/renderer_host/render_widget_host_view_android.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +1 line, -0 lines 0 comments Download
M content/browser/web_contents/aura/gesture_nav_simple.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +1 line, -0 lines 0 comments Download
M content/browser/web_contents/aura/overscroll_navigation_overlay.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +1 line, -0 lines 0 comments Download
M content/browser/web_contents/web_contents_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 3 chunks +7 lines, -0 lines 0 comments Download
M content/browser/web_contents/web_contents_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +4 lines, -0 lines 0 comments Download
M content/common/geolocation_messages.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +12 lines, -17 lines 0 comments Download
M content/public/browser/geolocation_permission_context.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 3 chunks +3 lines, -4 lines 0 comments Download
M content/public/browser/geolocation_provider.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +23 lines, -24 lines 0 comments Download

Messages

Total messages: 24 (0 generated)
jam
mvanouwerkerk: main reviewer caitkp: base/callback_list.h benm: android_webview and the changes to pausing a request which ...
6 years, 7 months ago (2014-05-08 07:12:40 UTC) #1
jam
+site-isolation-reviews
6 years, 7 months ago (2014-05-08 07:13:15 UTC) #2
Michael van Ouwerkerk
Nice! That does clean up a lot. Adding Marcus Bulach as additional Geolocation reviewer. I ...
6 years, 7 months ago (2014-05-08 13:20:00 UTC) #3
jam
https://codereview.chromium.org/273523007/diff/60001/base/callback_list.h File base/callback_list.h (right): https://codereview.chromium.org/273523007/diff/60001/base/callback_list.h#newcode3 base/callback_list.h:3: // DO NOT EDIT BY HAND!!! On 2014/05/08 13:20:02, ...
6 years, 7 months ago (2014-05-08 15:04:57 UTC) #4
benm (inactive)
aw changes look fine (but could we add the thread check back in case something ...
6 years, 7 months ago (2014-05-08 15:10:46 UTC) #5
jam
https://codereview.chromium.org/273523007/diff/60001/android_webview/native/aw_geolocation_permission_context.cc File android_webview/native/aw_geolocation_permission_context.cc (left): https://codereview.chromium.org/273523007/diff/60001/android_webview/native/aw_geolocation_permission_context.cc#oldcode27 android_webview/native/aw_geolocation_permission_context.cc:27: DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI)); On 2014/05/08 15:10:47, benm wrote: > can we ...
6 years, 7 months ago (2014-05-08 15:54:31 UTC) #6
jam
+isherman for components/autofill
6 years, 7 months ago (2014-05-08 17:23:37 UTC) #7
bulach
lgtm, truly love this simplification, thanks a lot jam! small nits and suggestions below: https://codereview.chromium.org/273523007/diff/120001/content/browser/geolocation/geolocation_dispatcher_host.cc ...
6 years, 7 months ago (2014-05-08 17:29:25 UTC) #8
jam
https://codereview.chromium.org/273523007/diff/120001/content/browser/geolocation/geolocation_dispatcher_host.cc File content/browser/geolocation/geolocation_dispatcher_host.cc (right): https://codereview.chromium.org/273523007/diff/120001/content/browser/geolocation/geolocation_dispatcher_host.cc#newcode90 content/browser/geolocation/geolocation_dispatcher_host.cc:90: // initialization here, defer to OnRegisterBridge which is triggered ...
6 years, 7 months ago (2014-05-08 19:09:52 UTC) #9
jam
+nasko for geolocation_messages.h
6 years, 7 months ago (2014-05-08 19:11:02 UTC) #10
Michael van Ouwerkerk
Thanks! lgtm
6 years, 7 months ago (2014-05-08 19:27:03 UTC) #11
benm (inactive)
lgtm, one question but it's late here and i'm probably just missing something obvious ;-) ...
6 years, 7 months ago (2014-05-08 20:23:32 UTC) #12
dcheng
https://codereview.chromium.org/273523007/diff/150001/base/callback_list.h.pump File base/callback_list.h.pump (right): https://codereview.chromium.org/273523007/diff/150001/base/callback_list.h.pump#newcode127 base/callback_list.h.pump:127: bool empty() { return callbacks_.empty(); } Super duper minor ...
6 years, 7 months ago (2014-05-08 21:28:04 UTC) #13
nasko
IPC LGTM
6 years, 7 months ago (2014-05-08 21:53:44 UTC) #14
jam
https://codereview.chromium.org/273523007/diff/150001/content/browser/geolocation/geolocation_dispatcher_host.cc File content/browser/geolocation/geolocation_dispatcher_host.cc (right): https://codereview.chromium.org/273523007/diff/150001/content/browser/geolocation/geolocation_dispatcher_host.cc#newcode102 content/browser/geolocation/geolocation_dispatcher_host.cc:102: geolocation_subscription_.reset(); On 2014/05/08 20:23:33, benm wrote: > sorry if ...
6 years, 7 months ago (2014-05-08 23:22:07 UTC) #15
jam
+brettw for base
6 years, 7 months ago (2014-05-08 23:50:51 UTC) #16
bulach
still lgtm, just clarifications: https://codereview.chromium.org/273523007/diff/120001/content/browser/geolocation/geolocation_dispatcher_host.cc File content/browser/geolocation/geolocation_dispatcher_host.cc (right): https://codereview.chromium.org/273523007/diff/120001/content/browser/geolocation/geolocation_dispatcher_host.cc#newcode121 content/browser/geolocation/geolocation_dispatcher_host.cc:121: DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); On 2014/05/08 19:09:53, jam ...
6 years, 7 months ago (2014-05-09 09:50:15 UTC) #17
jam
base->thakis
6 years, 7 months ago (2014-05-09 16:43:32 UTC) #18
Nico
s/thakis/ajwong/ for callback stuff
6 years, 7 months ago (2014-05-09 16:51:44 UTC) #19
Cait (Slow)
base/callback_list* lgtm, modulo my comment re: the empty() function. https://codereview.chromium.org/273523007/diff/230001/base/callback_list.h File base/callback_list.h (right): https://codereview.chromium.org/273523007/diff/230001/base/callback_list.h#newcode122 base/callback_list.h:122: ...
6 years, 7 months ago (2014-05-09 20:11:11 UTC) #20
jam
https://codereview.chromium.org/273523007/diff/230001/base/callback_list.h File base/callback_list.h (right): https://codereview.chromium.org/273523007/diff/230001/base/callback_list.h#newcode122 base/callback_list.h:122: bool empty() { return callbacks_.empty(); } On 2014/05/09 20:11:13, ...
6 years, 7 months ago (2014-05-09 20:30:51 UTC) #21
jam
back to brettw for owners lgtm. ajwong said caitp should review, which she did, but ...
6 years, 7 months ago (2014-05-09 20:32:31 UTC) #22
brettw
lgtm
6 years, 7 months ago (2014-05-09 20:36:21 UTC) #23
Ilya Sherman
6 years, 7 months ago (2014-05-09 20:39:30 UTC) #24
autofill changes LGTM (much nicer!).  Thanks!

Powered by Google App Engine
This is Rietveld 408576698