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

Side by Side Diff: chrome/browser/ui/views/frame/browser_view.cc

Issue 212603011: Newly created profiles should have the grey silhouette as avatar. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove duplicate references to resource for grey avatar. Created 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 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/views/frame/browser_view.h" 5 #include "chrome/browser/ui/views/frame/browser_view.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/auto_reset.h" 9 #include "base/auto_reset.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 565 matching lines...) Expand 10 before | Expand all | Expand 10 after
576 #if defined(OS_WIN) 576 #if defined(OS_WIN)
577 if (win8::IsSingleWindowMetroMode()) 577 if (win8::IsSingleWindowMetroMode())
578 otr_resource_id = IDR_OTR_ICON_FULLSCREEN; 578 otr_resource_id = IDR_OTR_ICON_FULLSCREEN;
579 #endif 579 #endif
580 } 580 }
581 581
582 return otr_resource_id; 582 return otr_resource_id;
583 } 583 }
584 584
585 int BrowserView::GetGuestIconResourceID() const { 585 int BrowserView::GetGuestIconResourceID() const {
586 return IDR_LOGIN_GUEST; 586 return ProfileInfoCache::GetPlaceholderAvatarIconResourceID();
587 } 587 }
588 588
589 bool BrowserView::ShouldShowAvatar() const { 589 bool BrowserView::ShouldShowAvatar() const {
590 #if defined(OS_CHROMEOS) 590 #if defined(OS_CHROMEOS)
591 if (!browser_->is_type_tabbed() && !browser_->is_app()) 591 if (!browser_->is_type_tabbed() && !browser_->is_app())
592 return false; 592 return false;
593 // Don't show incognito avatar in the guest session. 593 // Don't show incognito avatar in the guest session.
594 if (IsOffTheRecord() && !IsGuestSession()) 594 if (IsOffTheRecord() && !IsGuestSession())
595 return true; 595 return true;
596 // This function is called via BrowserNonClientFrameView::UpdateAvatarInfo 596 // This function is called via BrowserNonClientFrameView::UpdateAvatarInfo
(...skipping 1986 matching lines...) Expand 10 before | Expand all | Expand 10 after
2583 !GetLocationBar()->GetOmniboxView()->model()->popup_model()->IsOpen()) { 2583 !GetLocationBar()->GetOmniboxView()->model()->popup_model()->IsOpen()) {
2584 gfx::Point icon_bottom( 2584 gfx::Point icon_bottom(
2585 toolbar_->location_bar()->GetLocationBarAnchorPoint()); 2585 toolbar_->location_bar()->GetLocationBarAnchorPoint());
2586 ConvertPointToTarget(toolbar_->location_bar(), this, &icon_bottom); 2586 ConvertPointToTarget(toolbar_->location_bar(), this, &icon_bottom);
2587 gfx::Point infobar_top(0, infobar_container_->GetVerticalOverlap(NULL)); 2587 gfx::Point infobar_top(0, infobar_container_->GetVerticalOverlap(NULL));
2588 ConvertPointToTarget(infobar_container_, this, &infobar_top); 2588 ConvertPointToTarget(infobar_container_, this, &infobar_top);
2589 top_arrow_height = infobar_top.y() - icon_bottom.y(); 2589 top_arrow_height = infobar_top.y() - icon_bottom.y();
2590 } 2590 }
2591 return top_arrow_height; 2591 return top_arrow_height;
2592 } 2592 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698