| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 85 // Stub implementations of pure virtual Image functions. | 85 // Stub implementations of pure virtual Image functions. |
| 86 void destroyDecodedData(bool) override | 86 void destroyDecodedData(bool) override |
| 87 { | 87 { |
| 88 } | 88 } |
| 89 | 89 |
| 90 bool currentFrameKnownToBeOpaque() override | 90 bool currentFrameKnownToBeOpaque() override |
| 91 { | 91 { |
| 92 return false; | 92 return false; |
| 93 } | 93 } |
| 94 | 94 |
| 95 void draw(SkCanvas*, const SkPaint&, const FloatRect&, const FloatRect&, Res
pectImageOrientationEnum, ImageClampingMode) override | 95 void draw(SkCanvas*, const SkPaint&, const FloatRect&, const FloatRect&, Res
pectImageOrientationEnum, ImageClampingMode, const KURL&) override |
| 96 { | 96 { |
| 97 } | 97 } |
| 98 | 98 |
| 99 private: | 99 private: |
| 100 RefPtr<SkImage> m_image; | 100 RefPtr<SkImage> m_image; |
| 101 }; | 101 }; |
| 102 | 102 |
| 103 TEST(DragImageTest, NullHandling) | 103 TEST(DragImageTest, NullHandling) |
| 104 { | 104 { |
| 105 EXPECT_FALSE(DragImage::create(0)); | 105 EXPECT_FALSE(DragImage::create(0)); |
| (...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 217 { | 217 { |
| 218 SkAutoLockPixels lock1(dragBitmap); | 218 SkAutoLockPixels lock1(dragBitmap); |
| 219 SkAutoLockPixels lock2(expectedBitmap); | 219 SkAutoLockPixels lock2(expectedBitmap); |
| 220 for (int x = 0; x < dragBitmap.width(); ++x) | 220 for (int x = 0; x < dragBitmap.width(); ++x) |
| 221 for (int y = 0; y < dragBitmap.height(); ++y) | 221 for (int y = 0; y < dragBitmap.height(); ++y) |
| 222 EXPECT_EQ(expectedBitmap.getColor(x, y), dragBitmap.getColor(x,
y)); | 222 EXPECT_EQ(expectedBitmap.getColor(x, y), dragBitmap.getColor(x,
y)); |
| 223 } | 223 } |
| 224 } | 224 } |
| 225 | 225 |
| 226 } // namespace blink | 226 } // namespace blink |
| OLD | NEW |