| 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 | 6 * @fileoverview |
| 7 * 'settings-privacy-page' is the settings page containing privacy and | 7 * 'settings-privacy-page' is the settings page containing privacy and |
| 8 * security settings. | 8 * security settings. |
| 9 */ | 9 */ |
| 10 Polymer({ | 10 Polymer({ |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 111 browserProxy.setMetricsReportingEnabled(enabled); | 111 browserProxy.setMetricsReportingEnabled(enabled); |
| 112 }, | 112 }, |
| 113 | 113 |
| 114 /** | 114 /** |
| 115 * @param {!MetricsReporting} metricsReporting | 115 * @param {!MetricsReporting} metricsReporting |
| 116 * @private | 116 * @private |
| 117 */ | 117 */ |
| 118 setMetricsReporting_: function(metricsReporting) { | 118 setMetricsReporting_: function(metricsReporting) { |
| 119 if (this.metricsReporting_) { | 119 if (this.metricsReporting_) { |
| 120 // TODO(dbeam): hide if changed back to the value Chrome started with. | 120 // TODO(dbeam): hide if changed back to the value Chrome started with. |
| 121 this.showRestart_ = true; | 121 var changed = this.metricsReporting_.enabled != metricsReporting.enabled; |
| 122 this.showRestart_ = changed && !this.metricsReporting_.managed; |
| 122 } | 123 } |
| 123 this.metricsReporting_ = metricsReporting; | 124 this.metricsReporting_ = metricsReporting; |
| 124 }, | 125 }, |
| 125 | 126 |
| 126 /** @private */ | 127 /** @private */ |
| 127 onRestartTap_: function() { | 128 onRestartTap_: function() { |
| 128 settings.LifetimeBrowserProxyImpl.getInstance().restart(); | 129 settings.LifetimeBrowserProxyImpl.getInstance().restart(); |
| 129 }, | 130 }, |
| 130 </if> | 131 </if> |
| 131 | 132 |
| (...skipping 15 matching lines...) Expand all Loading... |
| 147 * The sub-page title for the site or content settings. | 148 * The sub-page title for the site or content settings. |
| 148 * @return {string} | 149 * @return {string} |
| 149 * @private | 150 * @private |
| 150 */ | 151 */ |
| 151 siteSettingsPageTitle_: function() { | 152 siteSettingsPageTitle_: function() { |
| 152 return loadTimeData.getBoolean('enableSiteSettings') ? | 153 return loadTimeData.getBoolean('enableSiteSettings') ? |
| 153 loadTimeData.getString('siteSettings') : | 154 loadTimeData.getString('siteSettings') : |
| 154 loadTimeData.getString('contentSettings'); | 155 loadTimeData.getString('contentSettings'); |
| 155 }, | 156 }, |
| 156 }); | 157 }); |
| OLD | NEW |