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

Side by Side Diff: chrome/browser/ui/webui/settings/settings_default_browser_handler.cc

Issue 2664753002: Remove base::StringValue (Closed)
Patch Set: Rebase Created 3 years, 9 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 unified diff | Download patch
OLDNEW
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 #include "chrome/browser/ui/webui/settings/settings_default_browser_handler.h" 5 #include "chrome/browser/ui/webui/settings/settings_default_browser_handler.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/metrics/histogram_macros.h" 8 #include "base/metrics/histogram_macros.h"
9 #include "base/metrics/user_metrics.h" 9 #include "base/metrics/user_metrics.h"
10 #include "chrome/browser/browser_process.h" 10 #include "chrome/browser/browser_process.h"
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 90
91 base::DictionaryValue dict; 91 base::DictionaryValue dict;
92 dict.SetBoolean("isDefault", state == shell_integration::IS_DEFAULT); 92 dict.SetBoolean("isDefault", state == shell_integration::IS_DEFAULT);
93 dict.SetBoolean("canBeDefault", 93 dict.SetBoolean("canBeDefault",
94 shell_integration::CanSetAsDefaultBrowser()); 94 shell_integration::CanSetAsDefaultBrowser());
95 dict.SetBoolean("isUnknownError", 95 dict.SetBoolean("isUnknownError",
96 state == shell_integration::UNKNOWN_DEFAULT); 96 state == shell_integration::UNKNOWN_DEFAULT);
97 dict.SetBoolean("isDisabledByPolicy", DefaultBrowserIsDisabledByPolicy()); 97 dict.SetBoolean("isDisabledByPolicy", DefaultBrowserIsDisabledByPolicy());
98 98
99 CallJavascriptFunction("cr.webUIListenerCallback", 99 CallJavascriptFunction("cr.webUIListenerCallback",
100 base::StringValue("settings.updateDefaultBrowserState"), dict); 100 base::Value("settings.updateDefaultBrowserState"),
101 dict);
101 } 102 }
102 103
103 } // namespace settings 104 } // namespace settings
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698