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

Unified Diff: third_party/WebKit/Source/modules/geolocation/Geolocation.cpp

Issue 1981233003: Finish migration from sameThreadBindForMojo to createBaseCallback. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 months 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/modules/geolocation/Geolocation.cpp
diff --git a/third_party/WebKit/Source/modules/geolocation/Geolocation.cpp b/third_party/WebKit/Source/modules/geolocation/Geolocation.cpp
index 3cc300090a5c2a973f0076b8c5f4372bdb1f9d8f..0c176a513dd325a449d196708b3d8d131d0eb9af 100644
--- a/third_party/WebKit/Source/modules/geolocation/Geolocation.cpp
+++ b/third_party/WebKit/Source/modules/geolocation/Geolocation.cpp
@@ -421,13 +421,13 @@ void Geolocation::requestPermission()
m_geolocationPermission = PermissionRequested;
frame->serviceRegistry()->connectToRemoteService(
mojo::GetProxy(&m_permissionService));
- m_permissionService.set_connection_error_handler(sameThreadBindForMojo(&Geolocation::onPermissionConnectionError, this));
+ m_permissionService.set_connection_error_handler(createBaseCallback(bind(&Geolocation::onPermissionConnectionError, WeakPersistentThisPointer<Geolocation>(this))));
// Ask the embedder: it maintains the geolocation challenge policy itself.
m_permissionService->RequestPermission(
mojom::blink::PermissionName::GEOLOCATION,
getExecutionContext()->getSecurityOrigin()->toString(),
- sameThreadBindForMojo(&Geolocation::onGeolocationPermissionUpdated, this));
+ createBaseCallback(bind<mojom::blink::PermissionStatus>(&Geolocation::onGeolocationPermissionUpdated, this)));
}
void Geolocation::makeSuccessCallbacks()
@@ -492,7 +492,7 @@ void Geolocation::updateGeolocationServiceConnection()
return;
frame()->serviceRegistry()->connectToRemoteService(mojo::GetProxy(&m_geolocationService));
- m_geolocationService.set_connection_error_handler(sameThreadBindForMojo(&Geolocation::onGeolocationConnectionError, this));
+ m_geolocationService.set_connection_error_handler(createBaseCallback(bind(&Geolocation::onGeolocationConnectionError, WeakPersistentThisPointer<Geolocation>(this))));
if (m_enableHighAccuracy)
m_geolocationService->SetHighAccuracy(true);
queryNextPosition();
@@ -500,8 +500,7 @@ void Geolocation::updateGeolocationServiceConnection()
void Geolocation::queryNextPosition()
{
- m_geolocationService->QueryNextPosition(
- sameThreadBindForMojo(&Geolocation::onPositionUpdated, this));
+ m_geolocationService->QueryNextPosition(createBaseCallback(bind<mojom::blink::GeopositionPtr>(&Geolocation::onPositionUpdated, this)));
}
void Geolocation::onPositionUpdated(mojom::blink::GeopositionPtr position)

Powered by Google App Engine
This is Rietveld 408576698