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

Side by Side Diff: third_party/WebKit/Source/platform/image-decoders/jpeg/JPEGImageDecoder.cpp

Issue 1746283002: Rename enums/functions that collide in chromium style in platform/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: get-names-13-platform: . Created 4 years, 9 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006 Apple Computer, Inc. 2 * Copyright (C) 2006 Apple Computer, Inc.
3 * 3 *
4 * Portions are Copyright (C) 2001-6 mozilla.org 4 * Portions are Copyright (C) 2001-6 mozilla.org
5 * 5 *
6 * Other contributors: 6 * Other contributors:
7 * Stuart Parmenter <stuart@mozilla.com> 7 * Stuart Parmenter <stuart@mozilla.com>
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Lesser General Public 10 * modify it under the terms of the GNU Lesser General Public
(...skipping 977 matching lines...) Expand 10 before | Expand all | Expand 10 after
988 if (hasImagePlanes()) 988 if (hasImagePlanes())
989 return outputRawData(m_reader.get(), m_imagePlanes.get()); 989 return outputRawData(m_reader.get(), m_imagePlanes.get());
990 990
991 if (m_frameBufferCache.isEmpty()) 991 if (m_frameBufferCache.isEmpty())
992 return false; 992 return false;
993 993
994 jpeg_decompress_struct* info = m_reader->info(); 994 jpeg_decompress_struct* info = m_reader->info();
995 995
996 // Initialize the framebuffer if needed. 996 // Initialize the framebuffer if needed.
997 ImageFrame& buffer = m_frameBufferCache[0]; 997 ImageFrame& buffer = m_frameBufferCache[0];
998 if (buffer.status() == ImageFrame::FrameEmpty) { 998 if (buffer.getStatus() == ImageFrame::FrameEmpty) {
999 ASSERT(info->output_width == static_cast<JDIMENSION>(m_decodedSize.width ())); 999 ASSERT(info->output_width == static_cast<JDIMENSION>(m_decodedSize.width ()));
1000 ASSERT(info->output_height == static_cast<JDIMENSION>(m_decodedSize.heig ht())); 1000 ASSERT(info->output_height == static_cast<JDIMENSION>(m_decodedSize.heig ht()));
1001 1001
1002 if (!buffer.setSize(info->output_width, info->output_height)) 1002 if (!buffer.setSize(info->output_width, info->output_height))
1003 return setFailed(); 1003 return setFailed();
1004 1004
1005 // The buffer is transparent outside the decoded area while the image is 1005 // The buffer is transparent outside the decoded area while the image is
1006 // loading. The image will be marked fully opaque in complete(). 1006 // loading. The image will be marked fully opaque in complete().
1007 buffer.setStatus(ImageFrame::FramePartial); 1007 buffer.setStatus(ImageFrame::FramePartial);
1008 buffer.setHasAlpha(true); 1008 buffer.setHasAlpha(true);
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
1070 // has failed. 1070 // has failed.
1071 if (!m_reader->decode(onlySize) && isAllDataReceived()) 1071 if (!m_reader->decode(onlySize) && isAllDataReceived())
1072 setFailed(); 1072 setFailed();
1073 1073
1074 // If decoding is done or failed, we don't need the JPEGImageReader anymore. 1074 // If decoding is done or failed, we don't need the JPEGImageReader anymore.
1075 if (isComplete(this, onlySize) || failed()) 1075 if (isComplete(this, onlySize) || failed())
1076 m_reader.clear(); 1076 m_reader.clear();
1077 } 1077 }
1078 1078
1079 } // namespace blink 1079 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698