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

Side by Side Diff: chrome/renderer/resources/extensions/web_view.js

Issue 95693002: <webview>: Expose transparency API (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // Shim that simulates a <webview> tag via Mutation Observers. 5 // Shim that simulates a <webview> tag via Mutation Observers.
6 // 6 //
7 // The actual tag is implemented via the browser plugin. The internals of this 7 // The actual tag is implemented via the browser plugin. The internals of this
8 // are hidden via Shadow DOM. 8 // are hidden via Shadow DOM.
9 9
10 'use strict'; 10 'use strict';
(...skipping 16 matching lines...) Expand all
27 // API can access it and not external developers. 27 // API can access it and not external developers.
28 var secret = {}; 28 var secret = {};
29 29
30 var WEB_VIEW_ATTRIBUTE_MAXHEIGHT = 'maxheight'; 30 var WEB_VIEW_ATTRIBUTE_MAXHEIGHT = 'maxheight';
31 var WEB_VIEW_ATTRIBUTE_MAXWIDTH = 'maxwidth'; 31 var WEB_VIEW_ATTRIBUTE_MAXWIDTH = 'maxwidth';
32 var WEB_VIEW_ATTRIBUTE_MINHEIGHT = 'minheight'; 32 var WEB_VIEW_ATTRIBUTE_MINHEIGHT = 'minheight';
33 var WEB_VIEW_ATTRIBUTE_MINWIDTH = 'minwidth'; 33 var WEB_VIEW_ATTRIBUTE_MINWIDTH = 'minwidth';
34 34
35 /** @type {Array.<string>} */ 35 /** @type {Array.<string>} */
36 var WEB_VIEW_ATTRIBUTES = [ 36 var WEB_VIEW_ATTRIBUTES = [
37 'allowtransparency',
38 'autosize',
37 'name', 39 'name',
38 'partition', 40 'partition',
39 'autosize',
40 WEB_VIEW_ATTRIBUTE_MINHEIGHT, 41 WEB_VIEW_ATTRIBUTE_MINHEIGHT,
41 WEB_VIEW_ATTRIBUTE_MINWIDTH, 42 WEB_VIEW_ATTRIBUTE_MINWIDTH,
42 WEB_VIEW_ATTRIBUTE_MAXHEIGHT, 43 WEB_VIEW_ATTRIBUTE_MAXHEIGHT,
43 WEB_VIEW_ATTRIBUTE_MAXWIDTH 44 WEB_VIEW_ATTRIBUTE_MAXWIDTH
44 ]; 45 ];
45 46
46 var CreateEvent = function(name) { 47 var CreateEvent = function(name) {
47 var eventOpts = {supportsListeners: true, supportsFilters: true}; 48 var eventOpts = {supportsListeners: true, supportsFilters: true};
48 return new EventBindings.Event(name, undefined, eventOpts); 49 return new EventBindings.Event(name, undefined, eventOpts);
49 }; 50 };
(...skipping 990 matching lines...) Expand 10 before | Expand all | Expand 10 after
1040 * Implemented when the experimental API is available. 1041 * Implemented when the experimental API is available.
1041 * @private 1042 * @private
1042 */ 1043 */
1043 WebViewInternal.prototype.maybeGetExperimentalPermissions_ = function() { 1044 WebViewInternal.prototype.maybeGetExperimentalPermissions_ = function() {
1044 return []; 1045 return [];
1045 }; 1046 };
1046 1047
1047 exports.WebView = WebView; 1048 exports.WebView = WebView;
1048 exports.WebViewInternal = WebViewInternal; 1049 exports.WebViewInternal = WebViewInternal;
1049 exports.CreateEvent = CreateEvent; 1050 exports.CreateEvent = CreateEvent;
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698