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

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

Issue 302463005: Add support for AMD to the extensions module system. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 (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 // Custom binding for the app_window API. 5 // Custom binding for the app_window API.
6 6
7 var appWindowNatives = requireNative('app_window_natives'); 7 var appWindowNatives = requireNative('app_window_natives');
8 var runtimeNatives = requireNative('runtime'); 8 var runtimeNatives = requireNative('runtime_natives');
9 var Binding = require('binding').Binding; 9 var Binding = require('binding').Binding;
10 var Event = require('event_bindings').Event; 10 var Event = require('event_bindings').Event;
11 var forEach = require('utils').forEach; 11 var forEach = require('utils').forEach;
12 var renderViewObserverNatives = requireNative('renderViewObserverNatives'); 12 var renderViewObserverNatives = requireNative('renderViewObserverNatives');
13 13
14 var appWindowData = null; 14 var appWindowData = null;
15 var currentAppWindow = null; 15 var currentAppWindow = null;
16 var currentWindowInternal = null; 16 var currentWindowInternal = null;
17 17
18 var kSetBoundsFunction = 'setBounds'; 18 var kSetBoundsFunction = 'setBounds';
(...skipping 365 matching lines...) Expand 10 before | Expand all | Expand 10 after
384 if (value === null) 384 if (value === null)
385 constraints[key] = 0; 385 constraints[key] = 0;
386 }); 386 });
387 387
388 currentWindowInternal.setSizeConstraints(boundsType, constraints); 388 currentWindowInternal.setSizeConstraints(boundsType, constraints);
389 } 389 }
390 390
391 exports.binding = appWindow.generate(); 391 exports.binding = appWindow.generate();
392 exports.onAppWindowClosed = onAppWindowClosed; 392 exports.onAppWindowClosed = onAppWindowClosed;
393 exports.updateAppWindowProperties = updateAppWindowProperties; 393 exports.updateAppWindowProperties = updateAppWindowProperties;
394 exports.appWindowShownForTests = onAppWindowShownForTests; 394 exports.appWindowShownForTests = onAppWindowShownForTests;
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698