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

Side by Side Diff: third_party/WebKit/Source/modules/imagecapture/ImageCapture.cpp

Issue 2589663003: mojo:: Rename mojo::GetProxy() to mojo::MakeRequest() (Closed)
Patch Set: Rebase Created 3 years, 12 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "modules/imagecapture/ImageCapture.h" 5 #include "modules/imagecapture/ImageCapture.h"
6 6
7 #include "bindings/core/v8/CallbackPromiseAdapter.h" 7 #include "bindings/core/v8/CallbackPromiseAdapter.h"
8 #include "bindings/core/v8/ScriptPromiseResolver.h" 8 #include "bindings/core/v8/ScriptPromiseResolver.h"
9 #include "core/dom/DOMException.h" 9 #include "core/dom/DOMException.h"
10 #include "core/dom/ExceptionCode.h" 10 #include "core/dom/ExceptionCode.h"
(...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after
266 266
267 return promise; 267 return promise;
268 } 268 }
269 269
270 ImageCapture::ImageCapture(ExecutionContext* context, MediaStreamTrack* track) 270 ImageCapture::ImageCapture(ExecutionContext* context, MediaStreamTrack* track)
271 : ContextLifecycleObserver(context), m_streamTrack(track) { 271 : ContextLifecycleObserver(context), m_streamTrack(track) {
272 DCHECK(m_streamTrack); 272 DCHECK(m_streamTrack);
273 DCHECK(!m_service.is_bound()); 273 DCHECK(!m_service.is_bound());
274 274
275 Platform::current()->interfaceProvider()->getInterface( 275 Platform::current()->interfaceProvider()->getInterface(
276 mojo::GetProxy(&m_service)); 276 mojo::MakeRequest(&m_service));
277 277
278 m_service.set_connection_error_handler(convertToBaseCallback(WTF::bind( 278 m_service.set_connection_error_handler(convertToBaseCallback(WTF::bind(
279 &ImageCapture::onServiceConnectionError, wrapWeakPersistent(this)))); 279 &ImageCapture::onServiceConnectionError, wrapWeakPersistent(this))));
280 } 280 }
281 281
282 void ImageCapture::onCapabilities( 282 void ImageCapture::onCapabilities(
283 ScriptPromiseResolver* resolver, 283 ScriptPromiseResolver* resolver,
284 media::mojom::blink::PhotoCapabilitiesPtr capabilities) { 284 media::mojom::blink::PhotoCapabilitiesPtr capabilities) {
285 DVLOG(1) << __func__; 285 DVLOG(1) << __func__;
286 if (!m_serviceRequests.contains(resolver)) 286 if (!m_serviceRequests.contains(resolver))
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
381 } 381 }
382 382
383 DEFINE_TRACE(ImageCapture) { 383 DEFINE_TRACE(ImageCapture) {
384 visitor->trace(m_streamTrack); 384 visitor->trace(m_streamTrack);
385 visitor->trace(m_serviceRequests); 385 visitor->trace(m_serviceRequests);
386 EventTargetWithInlineData::trace(visitor); 386 EventTargetWithInlineData::trace(visitor);
387 ContextLifecycleObserver::trace(visitor); 387 ContextLifecycleObserver::trace(visitor);
388 } 388 }
389 389
390 } // namespace blink 390 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698