Only set size and load URL on first attach

This commit is contained in:
Kevin Sawicki 2016-11-02 15:43:19 -07:00
parent b84fed5cb2
commit 133ad6e18b

View file

@ -78,7 +78,15 @@ const createGuest = function (embedder, params) {
guest.on('did-attach', function () {
params = this.attachParams
delete this.attachParams
const previouslyAttached = this.viewInstanceId != null
this.viewInstanceId = params.instanceId
// Only load URL and set size on first attach
if (previouslyAttached) {
return
}
this.setSize({
normal: {
width: params.elementWidth,