| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 /** | 5 /** |
| 6 * @fileoverview A helper object used from the "About" section to interact with | 6 * @fileoverview A helper object used from the "About" section to interact with |
| 7 * the browser. | 7 * the browser. |
| 8 */ | 8 */ |
| 9 | 9 |
| 10 <if expr="chromeos"> | 10 <if expr="chromeos"> |
| (...skipping 24 matching lines...) Expand all Loading... |
| 35 STABLE: 'stable-channel', | 35 STABLE: 'stable-channel', |
| 36 }; | 36 }; |
| 37 </if> | 37 </if> |
| 38 | 38 |
| 39 cr.define('settings', function() { | 39 cr.define('settings', function() { |
| 40 /** @interface */ | 40 /** @interface */ |
| 41 function AboutPageBrowserProxy() {} | 41 function AboutPageBrowserProxy() {} |
| 42 | 42 |
| 43 AboutPageBrowserProxy.prototype = { | 43 AboutPageBrowserProxy.prototype = { |
| 44 /** | 44 /** |
| 45 * Called once the page is ready. It results in one or more | 45 * Indicates to the browser that the page is ready. |
| 46 */ |
| 47 pageReady: function() {}, |
| 48 |
| 49 /** |
| 50 * Request update status from the browser. It results in one or more |
| 46 * 'update-status-changed' WebUI events. | 51 * 'update-status-changed' WebUI events. |
| 47 */ | 52 */ |
| 48 refreshUpdateStatus: function() {}, | 53 refreshUpdateStatus: function() {}, |
| 49 | 54 |
| 50 /** | 55 /** |
| 51 * Relaunches the browser. | 56 * Relaunches the browser. |
| 52 */ | 57 */ |
| 53 relaunchNow: function() {}, | 58 relaunchNow: function() {}, |
| 54 | 59 |
| 55 /** Opens the help page. */ | 60 /** Opens the help page. */ |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 90 | 95 |
| 91 /** | 96 /** |
| 92 * @implements {settings.AboutPageBrowserProxy} | 97 * @implements {settings.AboutPageBrowserProxy} |
| 93 * @constructor | 98 * @constructor |
| 94 */ | 99 */ |
| 95 function AboutPageBrowserProxyImpl() {} | 100 function AboutPageBrowserProxyImpl() {} |
| 96 cr.addSingletonGetter(AboutPageBrowserProxyImpl); | 101 cr.addSingletonGetter(AboutPageBrowserProxyImpl); |
| 97 | 102 |
| 98 AboutPageBrowserProxyImpl.prototype = { | 103 AboutPageBrowserProxyImpl.prototype = { |
| 99 /** @override */ | 104 /** @override */ |
| 105 pageReady: function() { |
| 106 chrome.send('aboutPageReady'); |
| 107 }, |
| 108 |
| 109 /** @override */ |
| 100 refreshUpdateStatus: function() { | 110 refreshUpdateStatus: function() { |
| 101 chrome.send('refreshUpdateStatus'); | 111 chrome.send('refreshUpdateStatus'); |
| 102 }, | 112 }, |
| 103 | 113 |
| 104 /** @override */ | 114 /** @override */ |
| 105 relaunchNow: function() { | 115 relaunchNow: function() { |
| 106 chrome.send('relaunchNow'); | 116 chrome.send('relaunchNow'); |
| 107 }, | 117 }, |
| 108 | 118 |
| 109 /** @override */ | 119 /** @override */ |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 149 return cr.sendWithPromise('getRegulatoryInfo'); | 159 return cr.sendWithPromise('getRegulatoryInfo'); |
| 150 } | 160 } |
| 151 </if> | 161 </if> |
| 152 }; | 162 }; |
| 153 | 163 |
| 154 return { | 164 return { |
| 155 AboutPageBrowserProxy: AboutPageBrowserProxy, | 165 AboutPageBrowserProxy: AboutPageBrowserProxy, |
| 156 AboutPageBrowserProxyImpl: AboutPageBrowserProxyImpl, | 166 AboutPageBrowserProxyImpl: AboutPageBrowserProxyImpl, |
| 157 }; | 167 }; |
| 158 }); | 168 }); |
| OLD | NEW |