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

Unified Diff: ash/system/user/tray_user.cc

Issue 10809008: Make spacing between uber tray items consistent with UI spec. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Move SetTrayImageItemBorder etc to tray_views. Created 8 years, 5 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 | « ash/system/user/tray_user.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/system/user/tray_user.cc
diff --git a/ash/system/user/tray_user.cc b/ash/system/user/tray_user.cc
index 4e81ed4548946f91752b76a5192c18eaa8d7f982..325d5e7a666339fff07772f0a416afb1f1ef8618 100644
--- a/ash/system/user/tray_user.cc
+++ b/ash/system/user/tray_user.cc
@@ -32,8 +32,6 @@
namespace {
const int kUserInfoVerticalPadding = 10;
-const int kUserInfoEmptyBorderLeftPadding = 6;
-const int kUserInfoEmptyBorderRightPadding = 1;
const int kUserIconSize = 27;
} // namespace
@@ -257,8 +255,6 @@ TrayUser::~TrayUser() {
views::View* TrayUser::CreateTrayView(user::LoginStatus status) {
CHECK(avatar_ == NULL);
avatar_ = new tray::RoundedImageView(kTrayRoundedBorderRadius);
- avatar_->set_border(views::Border::CreateEmptyBorder(
- 0, kUserInfoEmptyBorderLeftPadding, 0, kUserInfoEmptyBorderRightPadding));
UpdateAfterLoginStatusChange(status);
return avatar_;
}
@@ -299,6 +295,10 @@ void TrayUser::UpdateAfterLoginStatusChange(user::LoginStatus status) {
}
}
+void TrayUser::UpdateAfterShelfAlignmentChange(ShelfAlignment alignment) {
+ SetTrayImageItemBorder(avatar_, alignment);
+}
+
void TrayUser::OnUserUpdate() {
avatar_->SetImage(
ash::Shell::GetInstance()->tray_delegate()->GetUserImage(),
« no previous file with comments | « ash/system/user/tray_user.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698