OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 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 | 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 cr.define('options', function() { | 5 cr.define('options', function() { |
6 var OptionsPage = options.OptionsPage; | 6 var OptionsPage = options.OptionsPage; |
7 var ResetProfileSettingsBanner = options.ResetProfileSettingsBanner; | |
8 | 7 |
9 /** | 8 /** |
10 * ResetProfileSettingsOverlay class | 9 * ResetProfileSettingsOverlay class |
11 * Encapsulated handling of the 'Reset Profile Settings' overlay page. | 10 * Encapsulated handling of the 'Reset Profile Settings' overlay page. |
12 * @class | 11 * @class |
13 */ | 12 */ |
14 function ResetProfileSettingsOverlay() { | 13 function ResetProfileSettingsOverlay() { |
15 OptionsPage.call( | 14 OptionsPage.call( |
16 this, 'resetProfileSettings', | 15 this, 'resetProfileSettings', |
17 loadTimeData.getString('resetProfileSettingsOverlayTabTitle'), | 16 loadTimeData.getString('resetProfileSettingsOverlayTabTitle'), |
(...skipping 21 matching lines...) Expand all Loading... |
39 [$('send-settings').checked]); | 38 [$('send-settings').checked]); |
40 }; | 39 }; |
41 $('expand-feedback').onclick = function(event) { | 40 $('expand-feedback').onclick = function(event) { |
42 var feedbackTemplate = $('feedback-template'); | 41 var feedbackTemplate = $('feedback-template'); |
43 feedbackTemplate.hidden = !feedbackTemplate.hidden; | 42 feedbackTemplate.hidden = !feedbackTemplate.hidden; |
44 }; | 43 }; |
45 }, | 44 }, |
46 | 45 |
47 /** @override */ | 46 /** @override */ |
48 didShowPage: function() { | 47 didShowPage: function() { |
49 ResetProfileSettingsBanner.dismiss(); | |
50 chrome.send('onShowResetProfileDialog'); | 48 chrome.send('onShowResetProfileDialog'); |
51 }, | 49 }, |
52 | 50 |
53 /** @override */ | 51 /** @override */ |
54 didClosePage: function() { | 52 didClosePage: function() { |
55 chrome.send('onHideResetProfileDialog'); | 53 chrome.send('onHideResetProfileDialog'); |
56 }, | 54 }, |
57 }; | 55 }; |
58 | 56 |
59 /** | 57 /** |
(...skipping 27 matching lines...) Expand all Loading... |
87 var input = new JsEvalContext(feedbackListData); | 85 var input = new JsEvalContext(feedbackListData); |
88 var output = $('feedback-template'); | 86 var output = $('feedback-template'); |
89 jstProcess(input, output); | 87 jstProcess(input, output); |
90 }; | 88 }; |
91 | 89 |
92 // Export | 90 // Export |
93 return { | 91 return { |
94 ResetProfileSettingsOverlay: ResetProfileSettingsOverlay | 92 ResetProfileSettingsOverlay: ResetProfileSettingsOverlay |
95 }; | 93 }; |
96 }); | 94 }); |
OLD | NEW |