| Index: third_party/WebKit/LayoutTests/shapedetection/resources/mock-textdetection.js
|
| diff --git a/third_party/WebKit/LayoutTests/shapedetection/resources/mock-textdetection.js b/third_party/WebKit/LayoutTests/shapedetection/resources/mock-textdetection.js
|
| index 08195c993242b69e0061be7e34b6f1644f426c9d..333ea10abf6fb85800f7b674f7f777342b09dd42 100644
|
| --- a/third_party/WebKit/LayoutTests/shapedetection/resources/mock-textdetection.js
|
| +++ b/third_party/WebKit/LayoutTests/shapedetection/resources/mock-textdetection.js
|
| @@ -4,9 +4,8 @@ let mockTextDetectionReady = define(
|
| 'mockTextDetection',
|
| ['services/shape_detection/public/interfaces/textdetection.mojom',
|
| 'mojo/public/js/bindings',
|
| - 'mojo/public/js/core',
|
| 'content/public/renderer/interfaces',
|
| - ], (textDetection, bindings, mojo, interfaces) => {
|
| + ], (textDetection, bindings, interfaces) => {
|
|
|
| class MockTextDetection {
|
| constructor() {
|
| @@ -18,7 +17,7 @@ let mockTextDetectionReady = define(
|
| }
|
|
|
| detect(frame_data, width, height) {
|
| - let receivedStruct = mojo.mapBuffer(frame_data, 0, width*height*4, 0);
|
| + let receivedStruct = frame_data.mapBuffer(0, width*height*4);
|
| this.buffer_data_ = new Uint32Array(receivedStruct.buffer);
|
| return Promise.resolve({
|
| results: [
|
| @@ -32,7 +31,6 @@ let mockTextDetectionReady = define(
|
| },
|
| ],
|
| });
|
| - mojo.unmapBuffer(receivedStruct.buffer);
|
| }
|
|
|
| getFrameData() {
|
|
|