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

Side by Side Diff: chrome/browser/ui/views/download/download_item_view.cc

Issue 8363036: ui/gfx: Change Canvas::ScaleInt() to just Canvas::Scale(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: address Peter's review Created 9 years, 1 month 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
« no previous file with comments | « no previous file | chrome/browser/ui/views/find_bar_view.cc » ('j') | 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/download/download_item_view.h" 5 #include "chrome/browser/ui/views/download/download_item_view.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 726 matching lines...) Expand 10 before | Expand all | Expand 10 after
737 // Paint the background images. 737 // Paint the background images.
738 int x = kLeftPadding; 738 int x = kLeftPadding;
739 canvas->Save(); 739 canvas->Save();
740 if (base::i18n::IsRTL()) { 740 if (base::i18n::IsRTL()) {
741 // Since we do not have the mirrored images for 741 // Since we do not have the mirrored images for
742 // (hot_)body_image_set->top_left, (hot_)body_image_set->left, 742 // (hot_)body_image_set->top_left, (hot_)body_image_set->left,
743 // (hot_)body_image_set->bottom_left, and drop_down_image_set, 743 // (hot_)body_image_set->bottom_left, and drop_down_image_set,
744 // for RTL UI, we flip the canvas to draw those images mirrored. 744 // for RTL UI, we flip the canvas to draw those images mirrored.
745 // Consequently, we do not need to mirror the x-axis of those images. 745 // Consequently, we do not need to mirror the x-axis of those images.
746 canvas->Translate(gfx::Point(width(), 0)); 746 canvas->Translate(gfx::Point(width(), 0));
747 canvas->ScaleInt(-1, 1); 747 canvas->Scale(-1, 1);
748 } 748 }
749 PaintBitmaps(canvas, 749 PaintBitmaps(canvas,
750 body_image_set->top_left, body_image_set->left, 750 body_image_set->top_left, body_image_set->left,
751 body_image_set->bottom_left, 751 body_image_set->bottom_left,
752 x, box_y_, box_height_, body_image_set->top_left->width()); 752 x, box_y_, box_height_, body_image_set->top_left->width());
753 x += body_image_set->top_left->width(); 753 x += body_image_set->top_left->width();
754 PaintBitmaps(canvas, 754 PaintBitmaps(canvas,
755 body_image_set->top, body_image_set->center, 755 body_image_set->top, body_image_set->center,
756 body_image_set->bottom, 756 body_image_set->bottom,
757 x, box_y_, box_height_, center_width); 757 x, box_y_, box_height_, center_width);
(...skipping 350 matching lines...) Expand 10 before | Expand all | Expand 10 after
1108 // If the name has changed, notify assistive technology that the name 1108 // If the name has changed, notify assistive technology that the name
1109 // has changed so they can announce it immediately. 1109 // has changed so they can announce it immediately.
1110 if (new_name != accessible_name_) { 1110 if (new_name != accessible_name_) {
1111 accessible_name_ = new_name; 1111 accessible_name_ = new_name;
1112 if (GetWidget()) { 1112 if (GetWidget()) {
1113 GetWidget()->NotifyAccessibilityEvent( 1113 GetWidget()->NotifyAccessibilityEvent(
1114 this, ui::AccessibilityTypes::EVENT_NAME_CHANGED, true); 1114 this, ui::AccessibilityTypes::EVENT_NAME_CHANGED, true);
1115 } 1115 }
1116 } 1116 }
1117 } 1117 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/views/find_bar_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698