From 7f5fb4e6f9a9a3b82cc793eb4aeb5d8f35ac0a7d Mon Sep 17 00:00:00 2001 From: Cheng Zhao Date: Mon, 8 Dec 2014 21:10:59 -0800 Subject: [PATCH] Renamed "WebView" -> "WebViewImpl" in web_view.js and other files that import it Imported from: https://chromium.googlesource.com/chromium/src/+/a615ea0839c9276e80a7c0e66000dc7361ed68b6%5E%21/ --- .../renderer/lib/web-view/web-view-attributes.coffee | 4 ++-- atom/renderer/lib/web-view/web-view.coffee | 12 ++++++------ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/atom/renderer/lib/web-view/web-view-attributes.coffee b/atom/renderer/lib/web-view/web-view-attributes.coffee index cf1c063ec81..a255c30669a 100644 --- a/atom/renderer/lib/web-view/web-view-attributes.coffee +++ b/atom/renderer/lib/web-view/web-view-attributes.coffee @@ -1,4 +1,4 @@ -WebView = require './web-view' +WebViewImpl = require './web-view' guestViewInternal = require './guest-view-internal' webViewConstants = require './web-view-constants' @@ -144,7 +144,7 @@ class HttpReferrerAttribute extends WebViewAttribute @webViewImpl.parseSrcAttribute() # Sets up all of the webview attributes. -WebView::setupWebViewAttributes = -> +WebViewImpl::setupWebViewAttributes = -> @attributes = {} @attributes[webViewConstants.ATTRIBUTE_ALLOWTRANSPARENCY] = new AllowTransparencyAttribute(this) diff --git a/atom/renderer/lib/web-view/web-view.coffee b/atom/renderer/lib/web-view/web-view.coffee index fd3984f64f2..577313bff9e 100644 --- a/atom/renderer/lib/web-view/web-view.coffee +++ b/atom/renderer/lib/web-view/web-view.coffee @@ -9,7 +9,7 @@ nextId = 0 getNextId = -> ++nextId # Represents the internal state of the WebView node. -class WebView +class WebViewImpl constructor: (@webviewNode) -> v8Util.setHiddenValue @webviewNode, 'internal', this @attached = false @@ -37,7 +37,7 @@ class WebView createBrowserPluginNode: -> # We create BrowserPlugin as a custom element in order to observe changes # to attributes synchronously. - browserPluginNode = new WebView.BrowserPlugin() + browserPluginNode = new WebViewImpl.BrowserPlugin() v8Util.setHiddenValue browserPluginNode, 'internal', this browserPluginNode @@ -282,7 +282,7 @@ registerBrowserPluginElement = -> # Load the plugin immediately. unused = this.nonExistentAttribute - WebView.BrowserPlugin = webFrame.registerEmbedderCustomElement 'browserplugin', + WebViewImpl.BrowserPlugin = webFrame.registerEmbedderCustomElement 'browserplugin', extends: 'object', prototype: proto delete proto.createdCallback @@ -295,7 +295,7 @@ registerWebViewElement = -> proto = Object.create HTMLObjectElement.prototype proto.createdCallback = -> - new WebView(this) + new WebViewImpl(this) proto.attributeChangedCallback = (name, oldValue, newValue) -> internal = v8Util.getHiddenValue this, 'internal' @@ -342,7 +342,7 @@ registerWebViewElement = -> "getId" ] - # Forward proto.foo* method calls to WebView.foo*. + # Forward proto.foo* method calls to WebViewImpl.foo*. createHandler = (m) -> (args...) -> internal = v8Util.getHiddenValue this, 'internal' @@ -367,4 +367,4 @@ listener = (event) -> window.removeEventListener event.type, listener, useCapture window.addEventListener 'readystatechange', listener, true -module.exports = WebView +module.exports = WebViewImpl