Chromium Code Reviews| Index: chrome/browser/resources/settings/downloads_page/downloads_page.js |
| diff --git a/chrome/browser/resources/settings/downloads_page/downloads_page.js b/chrome/browser/resources/settings/downloads_page/downloads_page.js |
| index a18dfc7779b2a72a8b888866cac9f38e1ca21ac9..0cc04e566295dfc681e536c358eb770ed660cb65 100644 |
| --- a/chrome/browser/resources/settings/downloads_page/downloads_page.js |
| +++ b/chrome/browser/resources/settings/downloads_page/downloads_page.js |
| @@ -9,72 +9,70 @@ |
| * |
| * Example: |
| * |
| - * <core-animated-pages> |
| + * <iron-animated-pages> |
| * <cr-settings-downloads-page prefs="{{prefs}}"> |
| * </cr-settings-downloads-page> |
| * ... other pages ... |
| - * </core-animated-pages> |
| + * </iron-animated-pages> |
| * |
| * @group Chrome Settings Elements |
| * @element cr-settings-downloads-page |
| */ |
| -Polymer('cr-settings-downloads-page', { |
| - publish: { |
| +Polymer({ |
| + is: 'cr-settings-downloads-page', |
| + |
| + properties: { |
| /** |
| * Preferences state. |
| - * |
| - * @attribute prefs |
| - * @type CrSettingsPrefsElement |
| - * @default null |
| + * @type {?CrSettingsPrefsElement} |
| */ |
| - prefs: null, |
| + prefs: { |
| + type: Object, |
| + notify: true, |
| + }, |
| /** |
| * Route for the page. |
| - * |
| - * @attribute route |
| - * @type string |
| - * @default '' |
| */ |
| - route: '', |
| + route: String, |
| /** |
| * Whether the page is a subpage. |
| - * |
| - * @attribute subpage |
| - * @type boolean |
| - * @default false |
| */ |
| - subpage: false, |
| + subpage: { |
|
michaelpg
2015/05/12 06:50:19
same as above?
Jeremy Klein
2015/05/12 07:01:15
I kind of like the idea of being explicit with thi
michaelpg
2015/05/12 07:27:47
Either way.
Jeremy Klein
2015/05/12 22:24:17
Went back to add readOnly.
|
| + type: Boolean, |
| + value: false, |
| + }, |
| /** |
| * ID of the page. |
| - * |
| - * @attribute PAGE_ID |
| - * @const string |
| - * @default 'downloads' |
| */ |
| - PAGE_ID: 'downloads', |
| + PAGE_ID: { |
| + type: String, |
| + value: 'downloads', |
| + }, |
| /** |
| * Title for the page header and navigation menu. |
| - * |
| - * @attribute pageTitle |
| - * @type string |
| */ |
| - pageTitle: loadTimeData.getString('downloadsPageTitle'), |
| + pageTitle: { |
| + type: String, |
| + value: function() { |
| + return loadTimeData.getString('downloadsPageTitle'); |
| + }, |
| + }, |
| /** |
| - * Name of the 'core-icon' to show. |
| - * |
| - * @attribute icon |
| - * @type string |
| - * @default 'file-download' |
| + * Name of the 'iron-icon' to show. |
| */ |
| - icon: 'file-download', |
| + icon: { |
| + type: String, |
| + value: 'file-download', |
| + }, |
| }, |
| - selectDownloadLocation: function() { |
| + /** @private */ |
| + selectDownloadLocation_: function() { |
| // TODO(orenb): Communicate with the C++ to actually display a folder |
| // picker. |
| this.$.downloadsPath.value = '/Downloads'; |