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

Unified Diff: content/child/service_worker/service_worker_dispatcher.cc

Issue 2537953003: WebString: makes string16 conversions explicit (part 1: blink, content) (Closed)
Patch Set: fix Created 4 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 side-by-side diff with in-line comments
Download patch
Index: content/child/service_worker/service_worker_dispatcher.cc
diff --git a/content/child/service_worker/service_worker_dispatcher.cc b/content/child/service_worker/service_worker_dispatcher.cc
index c1934f515c181edec240f2fc7081ef25eac5cdae..3aef573277172772a95a20af2e1c7c97930a8ca3 100644
--- a/content/child/service_worker/service_worker_dispatcher.cc
+++ b/content/child/service_worker/service_worker_dispatcher.cc
@@ -622,7 +622,8 @@ void ServiceWorkerDispatcher::OnRegistrationError(
if (!callbacks)
return;
- callbacks->onError(WebServiceWorkerError(error_type, message));
+ callbacks->onError(
+ WebServiceWorkerError(error_type, blink::WebString::fromUTF16(message)));
pending_registration_callbacks_.Remove(request_id);
}
@@ -643,7 +644,8 @@ void ServiceWorkerDispatcher::OnUpdateError(
if (!callbacks)
return;
- callbacks->onError(WebServiceWorkerError(error_type, message));
+ callbacks->onError(
+ WebServiceWorkerError(error_type, blink::WebString::fromUTF16(message)));
pending_update_callbacks_.Remove(request_id);
}
@@ -666,7 +668,8 @@ void ServiceWorkerDispatcher::OnUnregistrationError(
if (!callbacks)
return;
- callbacks->onError(WebServiceWorkerError(error_type, message));
+ callbacks->onError(
+ WebServiceWorkerError(error_type, blink::WebString::fromUTF16(message)));
pending_unregistration_callbacks_.Remove(request_id);
}
@@ -689,7 +692,8 @@ void ServiceWorkerDispatcher::OnGetRegistrationError(
if (!callbacks)
return;
- callbacks->onError(WebServiceWorkerError(error_type, message));
+ callbacks->onError(
+ WebServiceWorkerError(error_type, blink::WebString::fromUTF16(message)));
pending_get_registration_callbacks_.Remove(request_id);
}
@@ -712,7 +716,8 @@ void ServiceWorkerDispatcher::OnGetRegistrationsError(
if (!callbacks)
return;
- callbacks->onError(WebServiceWorkerError(error_type, message));
+ callbacks->onError(
+ WebServiceWorkerError(error_type, blink::WebString::fromUTF16(message)));
pending_get_registrations_callbacks_.Remove(request_id);
}
@@ -871,7 +876,8 @@ void ServiceWorkerDispatcher::OnPostMessage(
base::ThreadTaskRunnerHandle::Get());
found->second->dispatchMessageEvent(
- WebServiceWorkerImpl::CreateHandle(worker), params.message, ports);
+ WebServiceWorkerImpl::CreateHandle(worker),
+ blink::WebString::fromUTF16(params.message), ports);
}
void ServiceWorkerDispatcher::AddServiceWorker(
« no previous file with comments | « content/child/notifications/notification_manager.cc ('k') | content/child/service_worker/web_service_worker_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698