OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 #import "chrome/browser/ui/cocoa/download/download_item_cell.h" | 5 #import "chrome/browser/ui/cocoa/download/download_item_cell.h" |
6 | 6 |
7 #include "base/sys_string_conversions.h" | 7 #include "base/sys_string_conversions.h" |
8 #include "chrome/browser/download/download_item.h" | 8 #include "chrome/browser/download/download_item.h" |
9 #include "chrome/browser/download/download_item_model.h" | 9 #include "chrome/browser/download/download_item_model.h" |
10 #include "chrome/browser/download/download_manager.h" | 10 #include "chrome/browser/download/download_manager.h" |
11 #include "chrome/browser/download/download_util.h" | 11 #include "chrome/browser/download/download_util.h" |
12 #import "chrome/browser/themes/browser_theme_provider.h" | 12 #import "chrome/browser/themes/browser_theme_provider.h" |
13 #import "chrome/browser/ui/cocoa/download/download_item_cell.h" | 13 #import "chrome/browser/ui/cocoa/download/download_item_cell.h" |
14 #import "chrome/browser/ui/cocoa/image_utils.h" | 14 #import "chrome/browser/ui/cocoa/image_utils.h" |
15 #import "chrome/browser/ui/cocoa/themed_window.h" | 15 #import "chrome/browser/ui/cocoa/themed_window.h" |
16 #include "gfx/canvas_skia_paint.h" | |
17 #include "grit/theme_resources.h" | 16 #include "grit/theme_resources.h" |
18 #import "third_party/GTM/AppKit/GTMNSAnimation+Duration.h" | 17 #import "third_party/GTM/AppKit/GTMNSAnimation+Duration.h" |
19 #import "third_party/GTM/AppKit/GTMNSColor+Luminance.h" | 18 #import "third_party/GTM/AppKit/GTMNSColor+Luminance.h" |
20 #include "ui/base/l10n/l10n_util.h" | 19 #include "ui/base/l10n/l10n_util.h" |
21 #include "ui/base/text/text_elider.h" | 20 #include "ui/base/text/text_elider.h" |
| 21 #include "ui/gfx/canvas_skia_paint.h" |
22 | 22 |
23 namespace { | 23 namespace { |
24 | 24 |
25 // Distance from top border to icon | 25 // Distance from top border to icon |
26 const CGFloat kImagePaddingTop = 7; | 26 const CGFloat kImagePaddingTop = 7; |
27 | 27 |
28 // Distance from left border to icon | 28 // Distance from left border to icon |
29 const CGFloat kImagePaddingLeft = 9; | 29 const CGFloat kImagePaddingLeft = 9; |
30 | 30 |
31 // Width of icon | 31 // Width of icon |
(...skipping 669 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
701 } | 701 } |
702 return self; | 702 return self; |
703 } | 703 } |
704 | 704 |
705 - (void)setCurrentProgress:(NSAnimationProgress)progress { | 705 - (void)setCurrentProgress:(NSAnimationProgress)progress { |
706 [super setCurrentProgress:progress]; | 706 [super setCurrentProgress:progress]; |
707 [cell_ animation:self progressed:progress]; | 707 [cell_ animation:self progressed:progress]; |
708 } | 708 } |
709 | 709 |
710 @end | 710 @end |
OLD | NEW |