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

Unified Diff: chrome/browser/ui/app_list/search/people/people_result.cc

Issue 458983004: Move app list search result icon sizes to app_list_constants. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 4 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/ui/app_list/search/people/people_result.cc
diff --git a/chrome/browser/ui/app_list/search/people/people_result.cc b/chrome/browser/ui/app_list/search/people/people_result.cc
index 70d065c0b656b9bbd79a50285e1c6e56bb5a492b..6e0504bdf0c0d2811f2164054ac0d18bb8f9f581 100644
--- a/chrome/browser/ui/app_list/search/people/people_result.cc
+++ b/chrome/browser/ui/app_list/search/people/people_result.cc
@@ -33,7 +33,6 @@ using extensions::api::hangouts_private::HangoutRequest;
namespace {
-const int kIconSize = 32;
const char kImageSizePath[] = "s64-p/";
const char kEmailUrlPrefix[] = "mailto:";
@@ -71,14 +70,15 @@ PeopleResult::PeopleResult(Profile* profile, scoped_ptr<Person> person)
RefreshHangoutsExtensionId();
SetDefaultActions();
+ int icon_size = GetPreferredIconSize();
image_ = gfx::ImageSkia(
- new UrlIconSource(base::Bind(&PeopleResult::OnIconLoaded,
- weak_factory_.GetWeakPtr()),
- profile_->GetRequestContext(),
- GetImageUrl(person_->image_url),
- kIconSize,
- IDR_PROFILE_PICTURE_LOADING),
- gfx::Size(kIconSize, kIconSize));
+ new UrlIconSource(
+ base::Bind(&PeopleResult::OnIconLoaded, weak_factory_.GetWeakPtr()),
+ profile_->GetRequestContext(),
+ GetImageUrl(person_->image_url),
+ icon_size,
+ IDR_PROFILE_PICTURE_LOADING),
+ gfx::Size(icon_size, icon_size));
SetIcon(image_);
}

Powered by Google App Engine
This is Rietveld 408576698