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 #include "base/basictypes.h" | 5 #include "base/basictypes.h" |
6 #include "gfx/blit.h" | 6 #include "gfx/blit.h" |
7 #include "gfx/point.h" | 7 #include "gfx/point.h" |
8 #include "gfx/rect.h" | 8 #include "gfx/rect.h" |
9 #include "skia/ext/platform_canvas.h" | 9 #include "skia/ext/platform_canvas.h" |
10 #include "testing/gtest/include/gtest/gtest.h" | 10 #include "testing/gtest/include/gtest/gtest.h" |
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
126 SetToCanvas<5, 5>(&canvas, initial_values); | 126 SetToCanvas<5, 5>(&canvas, initial_values); |
127 gfx::ScrollCanvas(&canvas, center_three, gfx::Point(2, 2)); | 127 gfx::ScrollCanvas(&canvas, center_three, gfx::Point(2, 2)); |
128 uint8 scroll_diagonal_expected[kCanvasHeight][kCanvasWidth] = { | 128 uint8 scroll_diagonal_expected[kCanvasHeight][kCanvasWidth] = { |
129 { 0x00, 0x01, 0x02, 0x03, 0x04 }, | 129 { 0x00, 0x01, 0x02, 0x03, 0x04 }, |
130 { 0x10, 0x11, 0x12, 0x13, 0x14 }, | 130 { 0x10, 0x11, 0x12, 0x13, 0x14 }, |
131 { 0x20, 0x21, 0x22, 0x23, 0x24 }, | 131 { 0x20, 0x21, 0x22, 0x23, 0x24 }, |
132 { 0x30, 0x31, 0x32, 0x11, 0x34 }, | 132 { 0x30, 0x31, 0x32, 0x11, 0x34 }, |
133 { 0x40, 0x41, 0x42, 0x43, 0x44 }}; | 133 { 0x40, 0x41, 0x42, 0x43, 0x44 }}; |
134 VerifyCanvasValues<5, 5>(&canvas, scroll_diagonal_expected); | 134 VerifyCanvasValues<5, 5>(&canvas, scroll_diagonal_expected); |
135 } | 135 } |
OLD | NEW |