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

Unified Diff: chrome/browser/ui/webui/options/chromeos/display_options_handler.cc

Issue 2415993002: Remove use of deprecated base::ListValue::Append(Value*) overload in //chrome/browser/ui/webui (Closed)
Patch Set: Add missing includes Created 4 years, 2 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
« no previous file with comments | « chrome/browser/ui/webui/options/chromeos/core_chromeos_options_handler.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/options/chromeos/display_options_handler.cc
diff --git a/chrome/browser/ui/webui/options/chromeos/display_options_handler.cc b/chrome/browser/ui/webui/options/chromeos/display_options_handler.cc
index d9daf77ccd182e636553d724e232fcfa8b433567..68c5fa355d25010149657b733dcf75ad690d80b1 100644
--- a/chrome/browser/ui/webui/options/chromeos/display_options_handler.cc
+++ b/chrome/browser/ui/webui/options/chromeos/display_options_handler.cc
@@ -158,12 +158,12 @@ scoped_refptr<display::ManagedDisplayMode> ConvertValueToManagedDisplayMode(
return mode;
}
-base::DictionaryValue* ConvertDisplayModeToValue(
+std::unique_ptr<base::DictionaryValue> ConvertDisplayModeToValue(
int64_t display_id,
const scoped_refptr<display::ManagedDisplayMode>& mode) {
bool is_internal = display::Display::HasInternalDisplay() &&
display::Display::InternalDisplayId() == display_id;
- base::DictionaryValue* result = new base::DictionaryValue();
+ auto result = base::MakeUnique<base::DictionaryValue>();
gfx::Size size_dip = mode->GetSizeInDIP(is_internal);
result->SetInteger("width", size_dip.width());
result->SetInteger("height", size_dip.height());
« no previous file with comments | « chrome/browser/ui/webui/options/chromeos/core_chromeos_options_handler.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698