Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(572)

Side by Side Diff: extensions/renderer/resources/guest_view/app_view/app_view.js

Issue 1165773004: Extract the element implementation logic to function mods in <webview>. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@qui
Patch Set: sync @tott Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 var DocumentNatives = requireNative('document_natives'); 5 var DocumentNatives = requireNative('document_natives');
6 var GuestViewContainer = require('guestViewContainer').GuestViewContainer; 6 var GuestViewContainer = require('guestViewContainer').GuestViewContainer;
7 var IdGenerator = requireNative('id_generator'); 7 var IdGenerator = requireNative('id_generator');
8 8
9 function AppViewImpl(appviewElement) { 9 function AppViewImpl(appviewElement) {
10 GuestViewContainer.call(this, appviewElement, 'appview'); 10 GuestViewContainer.call(this, appviewElement, 'appview');
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 this.guest.create(this.buildParams(), function() { 63 this.guest.create(this.buildParams(), function() {
64 if (!this.guest.getId()) { 64 if (!this.guest.getId()) {
65 var errorMsg = 'Unable to connect to app "' + app + '".'; 65 var errorMsg = 'Unable to connect to app "' + app + '".';
66 window.console.warn(errorMsg); 66 window.console.warn(errorMsg);
67 this.getErrorNode().innerText = errorMsg; 67 this.getErrorNode().innerText = errorMsg;
68 if (callback) { 68 if (callback) {
69 callback(false); 69 callback(false);
70 } 70 }
71 return; 71 return;
72 } 72 }
73 this.attachWindow(); 73 this.attachWindow$();
74 if (callback) { 74 if (callback) {
75 callback(true); 75 callback(true);
76 } 76 }
77 }.bind(this)); 77 }.bind(this));
78 }; 78 };
79 79
80 GuestViewContainer.registerElement(AppViewImpl); 80 GuestViewContainer.registerElement(AppViewImpl);
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698