OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 chrome.identityPrivate.onWebFlowRequest.addListener( | |
James Hawkins
2013/05/13 22:24:07
Is this a background page, or what? Should we be
Michael Courage
2013/05/14 17:10:56
This is the background page for the app. There isn
| |
6 function showAuthDialog(key, url, mode) { | |
7 var options = { | |
8 frame: 'none', | |
9 id: key, | |
10 minWidth: 1024, | |
11 minHeight: 768, | |
12 hidden: true | |
13 }; | |
14 chrome.app.window.create('scope_approval_dialog.html', options, | |
15 initializeWebFlow); | |
16 | |
17 function initializeWebFlow(win) { | |
18 win.contentWindow.addEventListener('load', function(event) { | |
19 var windowParam; | |
20 if (mode == 'interactive') | |
21 windowParam = win; | |
22 win.contentWindow.start(url, windowParam); | |
23 }); | |
24 } | |
25 }); | |
26 | |
OLD | NEW |