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

Side by Side Diff: chrome/browser/ui/views/tabs/tab.cc

Issue 2159913002: Fix apps page icon in tabstrip. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2785
Patch Set: Created 4 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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/tabs/tab.h" 5 #include "chrome/browser/ui/views/tabs/tab.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <limits> 8 #include <limits>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 canvas->sk_canvas()->drawRect( 137 canvas->sk_canvas()->drawRect(
138 SkRect::MakeXYWH(p.x() - radius, p.y() - radius, radius * 2, radius * 2), 138 SkRect::MakeXYWH(p.x() - radius, p.y() - radius, radius * 2, radius * 2),
139 paint); 139 paint);
140 } 140 }
141 141
142 // Returns whether the favicon for the given URL should be colored according to 142 // Returns whether the favicon for the given URL should be colored according to
143 // the browser theme. 143 // the browser theme.
144 bool ShouldThemifyFaviconForUrl(const GURL& url) { 144 bool ShouldThemifyFaviconForUrl(const GURL& url) {
145 return url.SchemeIs(content::kChromeUIScheme) && 145 return url.SchemeIs(content::kChromeUIScheme) &&
146 url.host() != chrome::kChromeUIHelpHost && 146 url.host() != chrome::kChromeUIHelpHost &&
147 url.host() != chrome::kChromeUIUberHost; 147 url.host() != chrome::kChromeUIUberHost &&
148 url.host() != chrome::kChromeUIAppLauncherPageHost;
148 } 149 }
149 150
150 } // namespace 151 } // namespace
151 152
152 //////////////////////////////////////////////////////////////////////////////// 153 ////////////////////////////////////////////////////////////////////////////////
153 // FaviconCrashAnimation 154 // FaviconCrashAnimation
154 // 155 //
155 // A custom animation subclass to manage the favicon crash animation. 156 // A custom animation subclass to manage the favicon crash animation.
156 class Tab::FaviconCrashAnimation : public gfx::LinearAnimation, 157 class Tab::FaviconCrashAnimation : public gfx::LinearAnimation,
157 public gfx::AnimationDelegate { 158 public gfx::AnimationDelegate {
(...skipping 1624 matching lines...) Expand 10 before | Expand all | Expand 10 after
1782 inactive_images_.image_c = rb.GetImageSkiaNamed(IDR_TAB_INACTIVE_CENTER); 1783 inactive_images_.image_c = rb.GetImageSkiaNamed(IDR_TAB_INACTIVE_CENTER);
1783 inactive_images_.image_r = rb.GetImageSkiaNamed(IDR_TAB_INACTIVE_RIGHT); 1784 inactive_images_.image_r = rb.GetImageSkiaNamed(IDR_TAB_INACTIVE_RIGHT);
1784 inactive_images_.l_width = inactive_images_.image_l->width(); 1785 inactive_images_.l_width = inactive_images_.image_l->width();
1785 inactive_images_.r_width = inactive_images_.image_r->width(); 1786 inactive_images_.r_width = inactive_images_.image_r->width();
1786 1787
1787 mask_images_.image_l = rb.GetImageSkiaNamed(IDR_TAB_ALPHA_LEFT); 1788 mask_images_.image_l = rb.GetImageSkiaNamed(IDR_TAB_ALPHA_LEFT);
1788 mask_images_.image_r = rb.GetImageSkiaNamed(IDR_TAB_ALPHA_RIGHT); 1789 mask_images_.image_r = rb.GetImageSkiaNamed(IDR_TAB_ALPHA_RIGHT);
1789 mask_images_.l_width = mask_images_.image_l->width(); 1790 mask_images_.l_width = mask_images_.image_l->width();
1790 mask_images_.r_width = mask_images_.image_r->width(); 1791 mask_images_.r_width = mask_images_.image_r->width();
1791 } 1792 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698