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

Unified Diff: chrome/browser/ui/webui/ntp/favicon_webui_handler.cc

Issue 1865213004: Convert //chrome/browser/ui from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 8 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/ntp/favicon_webui_handler.h ('k') | chrome/browser/ui/webui/ntp/new_tab_ui.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/ntp/favicon_webui_handler.cc
diff --git a/chrome/browser/ui/webui/ntp/favicon_webui_handler.cc b/chrome/browser/ui/webui/ntp/favicon_webui_handler.cc
index 4f40fdc63e4b46ae6d01edf26f18115255a70e55..1464b0750549dac6b83b03fb57efcb337fb4f7c4 100644
--- a/chrome/browser/ui/webui/ntp/favicon_webui_handler.cc
+++ b/chrome/browser/ui/webui/ntp/favicon_webui_handler.cc
@@ -108,7 +108,7 @@ void FaviconWebUIHandler::HandleGetFaviconDominantColor(
for (const auto& prepopulated_page : top_sites->GetPrepopulatedPages()) {
if (url == prepopulated_page.most_visited.url) {
base::StringValue dom_id_value(dom_id);
- scoped_ptr<base::StringValue> color(
+ std::unique_ptr<base::StringValue> color(
SkColorToCss(prepopulated_page.color));
web_ui()->CallJavascriptFunction("ntp.setFaviconDominantColor",
dom_id_value, *color);
@@ -131,7 +131,7 @@ void FaviconWebUIHandler::HandleGetFaviconDominantColor(
void FaviconWebUIHandler::OnFaviconDataAvailable(
int id,
const favicon_base::FaviconRawBitmapResult& bitmap_result) {
- scoped_ptr<base::StringValue> color_value;
+ std::unique_ptr<base::StringValue> color_value;
if (bitmap_result.is_valid())
color_value.reset(GetDominantColorCssString(bitmap_result.bitmap_data));
@@ -167,7 +167,7 @@ void FaviconWebUIHandler::NotifyAppIconReady(const std::string& extension_id) {
return;
scoped_refptr<base::RefCountedStaticMemory> bits_mem(
new base::RefCountedStaticMemory(&bits.front(), bits.size()));
- scoped_ptr<base::StringValue> color_value(
+ std::unique_ptr<base::StringValue> color_value(
GetDominantColorCssString(bits_mem));
base::StringValue id(extension_id);
web_ui()->CallJavascriptFunction(
« no previous file with comments | « chrome/browser/ui/webui/ntp/favicon_webui_handler.h ('k') | chrome/browser/ui/webui/ntp/new_tab_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698