| Index: third_party/WebKit/Source/modules/shapedetection/FaceDetector.h
|
| diff --git a/third_party/WebKit/Source/modules/shapedetection/FaceDetector.h b/third_party/WebKit/Source/modules/shapedetection/FaceDetector.h
|
| index 6afde515e3a691abbee6e0b60189b2b6092bb3f5..dc8a464978ac597e81376e5952edf2e199a9c081 100644
|
| --- a/third_party/WebKit/Source/modules/shapedetection/FaceDetector.h
|
| +++ b/third_party/WebKit/Source/modules/shapedetection/FaceDetector.h
|
| @@ -6,18 +6,34 @@
|
| #define FaceDetector_h
|
|
|
| #include "bindings/core/v8/ScriptPromise.h"
|
| +#include "bindings/core/v8/ScriptPromiseResolver.h"
|
| +#include "bindings/core/v8/ScriptWrappable.h"
|
| #include "modules/ModulesExport.h"
|
| -#include "modules/shapedetection/Detector.h"
|
| +#include "public/platform/modules/shapedetection/shapedetection.mojom-blink.h"
|
|
|
| namespace blink {
|
|
|
| -class MODULES_EXPORT FaceDetector final : public Detector {
|
| +class Document;
|
| +class HTMLImageElement;
|
| +class LocalFrame;
|
| +
|
| +class MODULES_EXPORT FaceDetector final
|
| + : public GarbageCollectedFinalized<FaceDetector>
|
| + , public ScriptWrappable {
|
| DEFINE_WRAPPERTYPEINFO();
|
|
|
| public:
|
| - static FaceDetector* create();
|
| -
|
| + static FaceDetector* create(const Document&);
|
| ScriptPromise detect(ScriptState*, const HTMLImageElement*);
|
| + DECLARE_TRACE();
|
| +
|
| +private:
|
| + explicit FaceDetector(LocalFrame&);
|
| + void onDetectFace(ScriptPromiseResolver*, mojo::WTFArray<mojom::blink::BoundingBoxPtr>);
|
| +
|
| + mojom::blink::ShapeDetectionPtr m_service;
|
| +
|
| + HeapHashSet<Member<ScriptPromiseResolver>> m_serviceRequests;
|
| };
|
|
|
| } // namespace blink
|
|
|