OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 /** @const */ var DictionaryWordsList = | 6 /** @const */ var DictionaryWordsList = |
7 options.dictionary_words.DictionaryWordsList; | 7 options.dictionary_words.DictionaryWordsList; |
8 /** @const */ var Page = cr.ui.pageManager.Page; | 8 /** @const */ var Page = cr.ui.pageManager.Page; |
9 /** @const */ var PageManager = cr.ui.pageManager.PageManager; | 9 /** @const */ var PageManager = cr.ui.pageManager.PageManager; |
10 | 10 |
11 /** | 11 /** |
12 * Adding and removing words in custom spelling dictionary. | 12 * Adding and removing words in custom spelling dictionary. |
13 * @constructor | 13 * @constructor |
14 * @extends {cr.ui.pageManager.Page} | 14 * @extends {cr.ui.pageManager.Page} |
15 */ | 15 */ |
16 function EditDictionaryOverlay() { | 16 function EditDictionaryOverlay() { |
17 Page.call(this, 'editDictionary', | 17 Page.call(this, 'editDictionary', |
18 loadTimeData.getString('languageDictionaryOverlayPage'), | 18 loadTimeData.getString('languageDictionaryOverlayPage'), |
19 'language-dictionary-overlay-page'); | 19 'language-dictionary-overlay-page'); |
20 } | 20 } |
21 | 21 |
22 cr.addSingletonGetter(EditDictionaryOverlay); | 22 cr.addSingletonGetter(EditDictionaryOverlay); |
23 | 23 |
24 EditDictionaryOverlay.prototype = { | 24 EditDictionaryOverlay.prototype = { |
25 __proto__: Page.prototype, | 25 __proto__: Page.prototype, |
26 | 26 |
27 /** | 27 /** |
28 * A list of words in the dictionary. | 28 * A list of words in the dictionary. |
29 * @type {DictionaryWordsList} | 29 * @type {options.dictionary_words.DictionaryWordsList} |
30 * @private | 30 * @private |
31 */ | 31 */ |
32 wordList_: null, | 32 wordList_: null, |
33 | 33 |
34 /** | 34 /** |
35 * The input field for searching for words in the dictionary. | 35 * The input field for searching for words in the dictionary. |
36 * @type {HTMLElement} | 36 * @type {HTMLElement} |
37 * @private | 37 * @private |
38 */ | 38 */ |
39 searchField_: null, | 39 searchField_: null, |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
107 }; | 107 }; |
108 | 108 |
109 EditDictionaryOverlay.getWordListForTesting = function() { | 109 EditDictionaryOverlay.getWordListForTesting = function() { |
110 return EditDictionaryOverlay.getInstance().wordList_; | 110 return EditDictionaryOverlay.getInstance().wordList_; |
111 }; | 111 }; |
112 | 112 |
113 return { | 113 return { |
114 EditDictionaryOverlay: EditDictionaryOverlay | 114 EditDictionaryOverlay: EditDictionaryOverlay |
115 }; | 115 }; |
116 }); | 116 }); |
OLD | NEW |