Re-add dirtyOnly to FrameSubscriber and document API change

This commit is contained in:
Heilig Benedek 2018-05-14 19:09:05 +02:00 committed by Samuel Attard
parent b9413fe59d
commit 60ba2013c4
4 changed files with 26 additions and 15 deletions

View file

@ -1637,15 +1637,17 @@ void WebContents::SendInputEvent(v8::Isolate* isolate,
}
void WebContents::BeginFrameSubscription(mate::Arguments* args) {
bool only_dirty = false;
FrameSubscriber::FrameCaptureCallback callback;
args->GetNext(&only_dirty);
if (!args->GetNext(&callback)) {
args->ThrowError();
return;
}
frame_subscriber_.reset(
new FrameSubscriber(isolate(), web_contents(), callback));
new FrameSubscriber(isolate(), web_contents(), callback, only_dirty));
}
void WebContents::EndFrameSubscription() {