[webkit-reviews] review granted: [Bug 217172] [WebXR] Make enumerateImmersiveXRDevices() asynchronnous : [Attachment 410641] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Oct 8 01:21:56 PDT 2020


youenn fablet <youennf at gmail.com> has granted Sergio Villar Senin
<svillar at igalia.com>'s request for review:
Bug 217172: [WebXR] Make enumerateImmersiveXRDevices() asynchronnous
https://bugs.webkit.org/show_bug.cgi?id=217172

Attachment 410641: Patch

https://bugs.webkit.org/attachment.cgi?id=410641&action=review




--- Comment #6 from youenn fablet <youennf at gmail.com> ---
Comment on attachment 410641
  --> https://bugs.webkit.org/attachment.cgi?id=410641
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=410641&action=review

> Source/WebCore/Modules/webxr/WebXRSystem.cpp:378
> +    obtainCurrentDevice(mode, init.requiredFeatures, init.optionalFeatures,
[this, protectedDocument = makeRef(document), immersive, init, mode, promise =
WTFMove(promise)](PlatformXR::Device* device) mutable {

COulbe auto*

> Source/WebCore/Modules/webxr/WebXRSystem.cpp:380
> +	       promise.reject(Exception { NotSupportedError });

Might be fine for now. But NotSupportedError might not be good in all early
return cases.

> Source/WebCore/Modules/webxr/WebXRSystem.cpp:421
> +	   promise.resolve(session);

Could WTFMove session


More information about the webkit-reviews mailing list