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

Side by Side Diff: third_party/WebKit/Source/platform/image-decoders/png/PNGImageDecoder.cpp

Issue 2700123003: DO NOT COMMIT: Results of running old (current) clang-format on Blink (Closed)
Patch Set: Created 3 years, 10 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 * Copyright (C) Research In Motion Limited 2009-2010. All rights reserved. 3 * Copyright (C) Research In Motion Limited 2009-2010. All rights reserved.
4 * 4 *
5 * Portions are Copyright (C) 2001 mozilla.org 5 * Portions are Copyright (C) 2001 mozilla.org
6 * 6 *
7 * Other contributors: 7 * Other contributors:
8 * Stuart Parmenter <stuart@mozilla.com> 8 * Stuart Parmenter <stuart@mozilla.com>
9 * 9 *
10 * This library is free software; you can redistribute it and/or 10 * This library is free software; you can redistribute it and/or
(...skipping 20 matching lines...) Expand all
31 * licenses (the MPL or the GPL) and not to allow others to use your 31 * licenses (the MPL or the GPL) and not to allow others to use your
32 * version of this file under the LGPL, indicate your decision by 32 * version of this file under the LGPL, indicate your decision by
33 * deletingthe provisions above and replace them with the notice and 33 * deletingthe provisions above and replace them with the notice and
34 * other provisions required by the MPL or the GPL, as the case may be. 34 * other provisions required by the MPL or the GPL, as the case may be.
35 * If you do not delete the provisions above, a recipient may use your 35 * If you do not delete the provisions above, a recipient may use your
36 * version of this file under any of the LGPL, the MPL or the GPL. 36 * version of this file under any of the LGPL, the MPL or the GPL.
37 */ 37 */
38 38
39 #include "platform/image-decoders/png/PNGImageDecoder.h" 39 #include "platform/image-decoders/png/PNGImageDecoder.h"
40 40
41 #include <memory>
41 #include "platform/image-decoders/png/PNGImageReader.h" 42 #include "platform/image-decoders/png/PNGImageReader.h"
42 #include "png.h" 43 #include "png.h"
43 #include "wtf/PtrUtil.h" 44 #include "wtf/PtrUtil.h"
44 #include <memory>
45 45
46 namespace blink { 46 namespace blink {
47 47
48 PNGImageDecoder::PNGImageDecoder(AlphaOption alphaOption, 48 PNGImageDecoder::PNGImageDecoder(AlphaOption alphaOption,
49 const ColorBehavior& colorBehavior, 49 const ColorBehavior& colorBehavior,
50 size_t maxDecodedBytes, 50 size_t maxDecodedBytes,
51 size_t offset) 51 size_t offset)
52 : ImageDecoder(alphaOption, colorBehavior, maxDecodedBytes), 52 : ImageDecoder(alphaOption, colorBehavior, maxDecodedBytes),
53 m_offset(offset) {} 53 m_offset(offset) {}
54 54
(...skipping 326 matching lines...) Expand 10 before | Expand all | Expand 10 after
381 // has failed. 381 // has failed.
382 if (!m_reader->decode(*m_data, onlySize) && isAllDataReceived()) 382 if (!m_reader->decode(*m_data, onlySize) && isAllDataReceived())
383 setFailed(); 383 setFailed();
384 384
385 // If decoding is done or failed, we don't need the PNGImageReader anymore. 385 // If decoding is done or failed, we don't need the PNGImageReader anymore.
386 if (isComplete(this) || failed()) 386 if (isComplete(this) || failed())
387 m_reader.reset(); 387 m_reader.reset();
388 } 388 }
389 389
390 } // namespace blink 390 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698