OLD | NEW |
1 <!doctype html> | 1 <!doctype html> |
2 <!-- | 2 <!-- |
3 Copyright (c) 2011 The Chromium Authors. All rights reserved. | 3 Copyright (c) 2011 The Chromium Authors. All rights reserved. |
4 Use of this source code is governed by a BSD-style license that can be | 4 Use of this source code is governed by a BSD-style license that can be |
5 found in the LICENSE file. | 5 found in the LICENSE file. |
6 --> | 6 --> |
7 <html> | 7 <html> |
| 8 <script type="text/javascript" src="chrome_ex_oauthsimple.js"></script> |
| 9 <script type="text/javascript" src="chrome_ex_oauth.js"></script> |
8 <script type="text/javascript"> | 10 <script type="text/javascript"> |
9 function setItem(key, value) { | 11 function setItem(key, value) { |
10 window.localStorage.setItem(key, value); | 12 window.localStorage.setItem(key, value); |
11 } | 13 } |
12 function getItem(key) { | 14 function getItem(key) { |
13 return window.localStorage.getItem(key); | 15 return window.localStorage.getItem(key); |
14 } | 16 } |
15 function clearAll() { | 17 function clearAll() { |
16 window.localStorage.clear(); | 18 window.localStorage.clear(); |
17 } | 19 } |
| 20 var oauth = ChromeExOAuth.initBackgroundPage({ |
| 21 'request_url': 'https://www.google.com/accounts/OAuthGetRequestToken', |
| 22 'authorize_url': 'https://www.google.com/accounts/OAuthAuthorizeToken', |
| 23 'access_url': 'https://www.google.com/accounts/OAuthGetAccessToken', |
| 24 'consumer_key': 'anonymous', |
| 25 'consumer_secret': 'anonymous', |
| 26 'scope': 'https://www.googleapis.com/auth/chromoting', |
| 27 'app_name': 'Remoting WebApp' |
| 28 }); |
18 </script> | 29 </script> |
19 </html> | 30 </html> |
OLD | NEW |