OLD | NEW |
---|---|
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 'settings-search-engine-entry' is a component for showing a | 6 * @fileoverview 'settings-search-engine-entry' is a component for showing a |
7 * search engine with its name, domain and query URL. | 7 * search engine with its name, domain and query URL. |
8 */ | 8 */ |
9 Polymer({ | 9 Polymer({ |
10 is: 'settings-search-engine-entry', | 10 is: 'settings-search-engine-entry', |
11 | 11 |
12 properties: { | 12 properties: { |
13 /** @type {!SearchEngine} */ | 13 /** @type {!SearchEngine} */ |
14 engine: Object, | 14 engine: Object, |
15 | 15 |
16 /** @private {boolean} */ | 16 /** @private {boolean} */ |
17 showEditSearchEngineDialog_: Boolean, | 17 showEditSearchEngineDialog_: Boolean, |
18 | 18 |
19 /** @type {boolean} */ | 19 /** @type {boolean} */ |
20 isDefault: { | 20 isDefault: { |
21 reflectToAttribute: true, | 21 reflectToAttribute: true, |
22 type: Boolean, | 22 type: Boolean, |
23 computed: 'computeIsDefault_(engine)' | 23 computed: 'computeIsDefault_(engine)' |
24 }, | 24 }, |
25 }, | 25 }, |
26 | 26 |
27 /** @private {!settings.SearchEnginesBrowserProxy} */ | 27 /** @private {settings.SearchEnginesBrowserProxy} */ |
tommycli
2016/06/30 21:29:43
and here
| |
28 browserProxy_: null, | 28 browserProxy_: null, |
29 | 29 |
30 /** @override */ | 30 /** @override */ |
31 created: function() { | 31 created: function() { |
32 this.browserProxy_ = settings.SearchEnginesBrowserProxyImpl.getInstance(); | 32 this.browserProxy_ = settings.SearchEnginesBrowserProxyImpl.getInstance(); |
33 }, | 33 }, |
34 | 34 |
35 /** | 35 /** |
36 * @return {boolean} | 36 * @return {boolean} |
37 * @private | 37 * @private |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
75 /** | 75 /** |
76 * @param {?string} url The icon URL if available. | 76 * @param {?string} url The icon URL if available. |
77 * @return {string} A set of icon URLs. | 77 * @return {string} A set of icon URLs. |
78 * @private | 78 * @private |
79 */ | 79 */ |
80 getIconSet_: function(url) { | 80 getIconSet_: function(url) { |
81 // Force default icon, if no |engine.iconURL| is available. | 81 // Force default icon, if no |engine.iconURL| is available. |
82 return cr.icon.getFaviconImageSet(url || ''); | 82 return cr.icon.getFaviconImageSet(url || ''); |
83 }, | 83 }, |
84 }); | 84 }); |
OLD | NEW |