Index: content/common/cursors/webcursor_unittest.cc |
diff --git a/content/common/cursors/webcursor_unittest.cc b/content/common/cursors/webcursor_unittest.cc |
index 7af1eb563981247d27e5c9a01b6f2d7b7482954f..6d4afe0922dc0a2947170b9c1c2b377535b955f5 100644 |
--- a/content/common/cursors/webcursor_unittest.cc |
+++ b/content/common/cursors/webcursor_unittest.cc |
@@ -222,7 +222,6 @@ TEST(WebCursorTest, AlphaConversion) { |
SkBitmap bitmap; |
SkPMColor testColor = SkPreMultiplyARGB(10, 255, 255, 255); |
bitmap.allocN32Pixels(1,1); |
- SkAutoLockPixels bitmap_lock(bitmap); |
*bitmap.getAddr32(0, 0) = testColor; |
CursorInfo cursor_info; |
cursor_info.type = WebCursorInfo::kTypeCustom; |
@@ -233,35 +232,26 @@ TEST(WebCursorTest, AlphaConversion) { |
// This round trip will convert the cursor to unpremultiplied form. |
custom_cursor.InitFromCursorInfo(cursor_info); |
custom_cursor.GetCursorInfo(&cursor_info); |
- { |
- SkAutoLockPixels lock(cursor_info.custom_image); |
- EXPECT_EQ(kUnpremul_SkAlphaType, cursor_info.custom_image.alphaType()); |
- EXPECT_EQ(testColor, |
- SkPreMultiplyColor(*cursor_info.custom_image.getAddr32(0,0))); |
- } |
+ EXPECT_EQ(kUnpremul_SkAlphaType, cursor_info.custom_image.alphaType()); |
+ EXPECT_EQ(testColor, |
+ SkPreMultiplyColor(*cursor_info.custom_image.getAddr32(0, 0))); |
// Second round trip should not do any conversion because data is already |
// unpremultiplied. |
custom_cursor.InitFromCursorInfo(cursor_info); |
custom_cursor.GetCursorInfo(&cursor_info); |
- { |
- SkAutoLockPixels lock(cursor_info.custom_image); |
- EXPECT_EQ(kUnpremul_SkAlphaType, cursor_info.custom_image.alphaType()); |
- EXPECT_EQ(testColor, |
- SkPreMultiplyColor(*cursor_info.custom_image.getAddr32(0,0))); |
- } |
+ EXPECT_EQ(kUnpremul_SkAlphaType, cursor_info.custom_image.alphaType()); |
+ EXPECT_EQ(testColor, |
+ SkPreMultiplyColor(*cursor_info.custom_image.getAddr32(0, 0))); |
#if defined(OS_MACOSX) |
// On MacOS, test roundtrip through NSCursor conversion. |
WebCursor custom_cursor_copy; |
custom_cursor_copy.InitFromNSCursor(custom_cursor.GetNativeCursor()); |
custom_cursor_copy.GetCursorInfo(&cursor_info); |
- { |
- SkAutoLockPixels lock(cursor_info.custom_image); |
- EXPECT_EQ(kUnpremul_SkAlphaType, cursor_info.custom_image.alphaType()); |
- EXPECT_EQ(testColor, |
- SkPreMultiplyColor(*cursor_info.custom_image.getAddr32(0,0))); |
- } |
+ EXPECT_EQ(kUnpremul_SkAlphaType, cursor_info.custom_image.alphaType()); |
+ EXPECT_EQ(testColor, |
+ SkPreMultiplyColor(*cursor_info.custom_image.getAddr32(0, 0))); |
#endif |
} |