Update FrameSubscriber implementation

This commit is contained in:
Heilig Benedek 2018-05-14 17:55:39 +02:00 committed by Samuel Attard
parent ca8843102a
commit b9413fe59d
4 changed files with 65 additions and 122 deletions

View file

@ -1644,10 +1644,8 @@ void WebContents::BeginFrameSubscription(mate::Arguments* args) {
return;
}
auto* const view = web_contents()->GetRenderWidgetHostView();
if (view) {
frame_subscriber_.reset(new FrameSubscriber(isolate(), view, callback));
}
frame_subscriber_.reset(
new FrameSubscriber(isolate(), web_contents(), callback));
}
void WebContents::EndFrameSubscription() {