Merge pull request #6128 from gerhardberger/webview-size-issue

Fixes transformed webview size
This commit is contained in:
Cheng Zhao 2016-06-20 00:13:30 +00:00 committed by GitHub
commit b4232d9230

View file

@ -166,6 +166,12 @@ var WebViewImpl = (function () {
resizeEvent = new Event('resize', { resizeEvent = new Event('resize', {
bubbles: true bubbles: true
}) })
// Using client size values, because when a webview is transformed `newSize`
// is incorrect
newSize.width = this.webviewNode.clientWidth
newSize.height = this.webviewNode.clientHeight
resizeEvent.newWidth = newSize.width resizeEvent.newWidth = newSize.width
resizeEvent.newHeight = newSize.height resizeEvent.newHeight = newSize.height
this.dispatchEvent(resizeEvent) this.dispatchEvent(resizeEvent)