Revert r3036. This change breaks loading images as
described in Chromium issue 114107. The Chromium break
may be fixed by WebKit patch 78239, at which time
this patch can be reapplied.
Review URL: https://codereview.appspot.com/5675077
git-svn-id: http://skia.googlecode.com/svn/trunk@3219 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/src/core/SkBitmap.cpp b/src/core/SkBitmap.cpp
index 9a21320..58d0bd8 100644
--- a/src/core/SkBitmap.cpp
+++ b/src/core/SkBitmap.cpp
@@ -821,7 +821,6 @@
SkBitmap dst;
dst.setConfig(this->config(), r.width(), r.height(), this->rowBytes());
- dst.setIsOpaque(this->isOpaque());
dst.setIsVolatile(this->isVolatile());
if (fPixelRef) {
diff --git a/tests/BitmapCopyTest.cpp b/tests/BitmapCopyTest.cpp
index a89064b..d5fd7df 100644
--- a/tests/BitmapCopyTest.cpp
+++ b/tests/BitmapCopyTest.cpp
@@ -312,14 +312,11 @@
SkBitmap subset;
SkIRect r;
r.set(1, 1, 2, 2);
- bitmap.setIsOpaque(true);
bitmap.setIsVolatile(true);
if (bitmap.extractSubset(&subset, r)) {
REPORTER_ASSERT(reporter, subset.width() == 1);
REPORTER_ASSERT(reporter, subset.height() == 1);
REPORTER_ASSERT(reporter,
- subset.isOpaque() == bitmap.isOpaque());
- REPORTER_ASSERT(reporter,
subset.isVolatile() == true);
SkBitmap copy;
@@ -336,12 +333,9 @@
REPORTER_ASSERT(reporter,
(copy.getColorTable() != NULL) == hasCT);
}
- bitmap.setIsOpaque(false);
bitmap.setIsVolatile(false);
if (bitmap.extractSubset(&subset, r)) {
REPORTER_ASSERT(reporter,
- subset.isOpaque() == bitmap.isOpaque());
- REPORTER_ASSERT(reporter,
subset.isVolatile() == false);
}
}