OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 var AddLanguageOverlay = options.AddLanguageOverlay; | 5 var AddLanguageOverlay = options.AddLanguageOverlay; |
6 var AdvancedOptions = options.AdvancedOptions; | 6 var AdvancedOptions = options.AdvancedOptions; |
7 var AlertOverlay = options.AlertOverlay; | 7 var AlertOverlay = options.AlertOverlay; |
8 var AutofillEditAddressOverlay = options.AutofillEditAddressOverlay; | 8 var AutofillEditAddressOverlay = options.AutofillEditAddressOverlay; |
9 var AutofillEditCreditCardOverlay = options.AutofillEditCreditCardOverlay; | 9 var AutofillEditCreditCardOverlay = options.AutofillEditCreditCardOverlay; |
10 var AutofillOptions = options.AutofillOptions; | 10 var AutofillOptions = options.AutofillOptions; |
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
204 $('settings-title').onclick = function() { | 204 $('settings-title').onclick = function() { |
205 OptionsPage.navigateToPage(BrowserOptions.getInstance().name); | 205 OptionsPage.navigateToPage(BrowserOptions.getInstance().name); |
206 }; | 206 }; |
207 } | 207 } |
208 | 208 |
209 document.addEventListener('DOMContentLoaded', load); | 209 document.addEventListener('DOMContentLoaded', load); |
210 | 210 |
211 window.onpopstate = function(e) { | 211 window.onpopstate = function(e) { |
212 options.OptionsPage.setState(e.state); | 212 options.OptionsPage.setState(e.state); |
213 }; | 213 }; |
| 214 |
| 215 window.onbeforeunload = function() { |
| 216 options.OptionsPage.willClose(); |
| 217 }; |
OLD | NEW |