Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2360)

Unified Diff: chrome/browser/resources/options/browser_options.js

Issue 938713004: Add Now setting and migration logic. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Conditionalize include Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resources/options/browser_options.js
diff --git a/chrome/browser/resources/options/browser_options.js b/chrome/browser/resources/options/browser_options.js
index d9470ff7ed4984d105cf420a9d0d7b4514ce23ab..80d433c7db249dd8f7739657ffc8139d64ddd753 100644
--- a/chrome/browser/resources/options/browser_options.js
+++ b/chrome/browser/resources/options/browser_options.js
@@ -246,6 +246,8 @@ cr.define('options', function() {
$('hotword-always-on-search-checkbox');
chrome.send('requestHotwordAvailable');
+ chrome.send('requestGoogleNowAvailable');
+
if ($('set-wallpaper')) {
$('set-wallpaper').onclick = function(event) {
chrome.send('openWallpaperManager');
@@ -1254,6 +1256,15 @@ cr.define('options', function() {
},
/**
+ * Controls the visibility of the Now settings.
+ * @param {boolean} visible Whether to show Now settings.
+ * @private
+ */
+ setNowSectionVisible_: function(visible) {
+ $('google-now-launcher').hidden = !visible;
+ },
+
+ /**
* Activates the Audio History section of the Settings page.
* @param {boolean} visible Whether the audio history section is visible.
* @param {string} labelText Text describing current audio history state.
@@ -2173,6 +2184,7 @@ cr.define('options', function() {
'setHotwordRetrainLinkVisible',
'setNativeThemeButtonEnabled',
'setNetworkPredictionValue',
+ 'setNowSectionVisible',
'setHighContrastCheckboxState',
'setAllHotwordSectionsVisible',
'setMetricsReportingCheckboxState',
« no previous file with comments | « chrome/browser/resources/options/browser_options.html ('k') | chrome/browser/ui/app_list/google_now_extension.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698