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

Unified Diff: src/core/SkBitmapDevice.cpp

Issue 227643005: remove SK_SUPPORT_LEGACY_COMPATIBLEDEVICE_CONFIG (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 6 years, 8 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « include/gpu/SkGpuDevice.h ('k') | src/core/SkDevice.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkBitmapDevice.cpp
diff --git a/src/core/SkBitmapDevice.cpp b/src/core/SkBitmapDevice.cpp
index dd43e963e6e3c9639ee27d342746fc75e09d65df..ba529a766b5c0595268f3d9e032718f419730a0f 100644
--- a/src/core/SkBitmapDevice.cpp
+++ b/src/core/SkBitmapDevice.cpp
@@ -68,33 +68,6 @@ SkBitmapDevice::SkBitmapDevice(const SkBitmap& bitmap, const SkDeviceProperties&
SkASSERT(valid_for_bitmap_device(bitmap.info(), NULL));
}
-#ifdef SK_SUPPORT_LEGACY_COMPATIBLEDEVICE_CONFIG
-void SkBitmapDevice::init(SkBitmap::Config config, int width, int height, bool isOpaque) {
- fBitmap.setConfig(config, width, height, 0, isOpaque ?
- kOpaque_SkAlphaType : kPremul_SkAlphaType);
-
- if (SkBitmap::kNo_Config != config) {
- if (!fBitmap.allocPixels()) {
- // indicate failure by zeroing our bitmap
- fBitmap.setConfig(config, 0, 0, 0, isOpaque ?
- kOpaque_SkAlphaType : kPremul_SkAlphaType);
- } else if (!isOpaque) {
- fBitmap.eraseColor(SK_ColorTRANSPARENT);
- }
- }
-}
-
-SkBitmapDevice::SkBitmapDevice(SkBitmap::Config config, int width, int height, bool isOpaque) {
- this->init(config, width, height, isOpaque);
-}
-
-SkBitmapDevice::SkBitmapDevice(SkBitmap::Config config, int width, int height, bool isOpaque,
- const SkDeviceProperties& deviceProperties)
- : SkBaseDevice(deviceProperties)
-{
- this->init(config, width, height, isOpaque);
-}
-#endif
SkBitmapDevice* SkBitmapDevice::Create(const SkImageInfo& origInfo,
const SkDeviceProperties* props) {
SkImageInfo info = origInfo;
« no previous file with comments | « include/gpu/SkGpuDevice.h ('k') | src/core/SkDevice.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698