From 97139b7487db38b242ea8a128896f1c4b6072672 Mon Sep 17 00:00:00 2001 From: Cheng Zhao Date: Wed, 22 Oct 2014 23:37:27 +0800 Subject: [PATCH] Fix js errors in webview --- atom/renderer/lib/webview.coffee | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/atom/renderer/lib/webview.coffee b/atom/renderer/lib/webview.coffee index 0e72d759466c..2f14bb9adac2 100644 --- a/atom/renderer/lib/webview.coffee +++ b/atom/renderer/lib/webview.coffee @@ -66,7 +66,7 @@ class Partition # Represents the internal state of the WebView node. class WebView constructor: (@webviewNode) -> - v8Util.setHiddenValue webviewNode, 'internal', this + v8Util.setHiddenValue @webviewNode, 'internal', this @attached = false @pendingGuestCreation = false @elementAttached = false @@ -471,7 +471,7 @@ registerBrowserPluginElement = -> @style.height = '100%' proto.attributeChangedCallback = (name, oldValue, newValue) -> - internal = v8Util.getHiddenValue 'internal' + internal = v8Util.getHiddenValue this, 'internal' return unless internal internal.handleBrowserPluginAttributeMutation name, oldValue, newValue @@ -495,18 +495,18 @@ registerWebViewElement = -> new WebView(this) proto.attributeChangedCallback = (name, oldValue, newValue) -> - internal = v8Util.getHiddenValue 'internal' + internal = v8Util.getHiddenValue this, 'internal' return unless internal internal.handleWebviewAttributeMutation name, oldValue, newValue proto.detachedCallback = -> - internal = v8Util.getHiddenValue 'internal' + internal = v8Util.getHiddenValue this, 'internal' return unless internal internal.elementAttached = false internal.reset() proto.attachedCallback = -> - internal = v8Util.getHiddenValue 'internal' + internal = v8Util.getHiddenValue this, 'internal' return unless internal unless internal.elementAttached internal.elementAttached = true