| OLD | NEW |
| 1 /* | 1 /* |
| 2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) | 2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) |
| 3 Copyright (C) 2001 Dirk Mueller (mueller@kde.org) | 3 Copyright (C) 2001 Dirk Mueller (mueller@kde.org) |
| 4 Copyright (C) 2002 Waldo Bastian (bastian@kde.org) | 4 Copyright (C) 2002 Waldo Bastian (bastian@kde.org) |
| 5 Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) | 5 Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) |
| 6 Copyright (C) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved. | 6 Copyright (C) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved. |
| 7 | 7 |
| 8 This library is free software; you can redistribute it and/or | 8 This library is free software; you can redistribute it and/or |
| 9 modify it under the terms of the GNU Library General Public | 9 modify it under the terms of the GNU Library General Public |
| 10 License as published by the Free Software Foundation; either | 10 License as published by the Free Software Foundation; either |
| (...skipping 489 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 500 // the attempt to build a placeholder image failed. | 500 // the attempt to build a placeholder image failed. |
| 501 clearImage(); | 501 clearImage(); |
| 502 } | 502 } |
| 503 } | 503 } |
| 504 | 504 |
| 505 if (!m_image || m_image->isNull()) { | 505 if (!m_image || m_image->isNull()) { |
| 506 size_t size = encodedSize(); | 506 size_t size = encodedSize(); |
| 507 clear(); | 507 clear(); |
| 508 if (!errorOccurred()) | 508 if (!errorOccurred()) |
| 509 setStatus(DecodeError); | 509 setStatus(DecodeError); |
| 510 if (!allDataReceived && loader()) | 510 if (!allDataReceived && loader()) { |
| 511 loader()->didFinishLoading(nullptr, monotonicallyIncreasingTime(), size); | 511 loader()->didFinishLoading(nullptr, monotonicallyIncreasingTime(), size, |
| 512 size); |
| 513 } |
| 512 memoryCache()->remove(this); | 514 memoryCache()->remove(this); |
| 513 } | 515 } |
| 514 | 516 |
| 515 // It would be nice to only redraw the decoded band of the image, but with the | 517 // It would be nice to only redraw the decoded band of the image, but with the |
| 516 // current design (decoding delayed until painting) that seems hard. | 518 // current design (decoding delayed until painting) that seems hard. |
| 517 notifyObservers(); | 519 notifyObservers(); |
| 518 } | 520 } |
| 519 | 521 |
| 520 void ImageResource::updateImageAndClearBuffer() { | 522 void ImageResource::updateImageAndClearBuffer() { |
| 521 clearImage(); | 523 clearImage(); |
| (...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 718 WebServiceWorkerResponseTypeOpaque; | 720 WebServiceWorkerResponseTypeOpaque; |
| 719 } | 721 } |
| 720 if (!getImage()->currentFrameHasSingleSecurityOrigin()) | 722 if (!getImage()->currentFrameHasSingleSecurityOrigin()) |
| 721 return false; | 723 return false; |
| 722 if (passesAccessControlCheck(securityOrigin)) | 724 if (passesAccessControlCheck(securityOrigin)) |
| 723 return true; | 725 return true; |
| 724 return !securityOrigin->taintsCanvas(response().url()); | 726 return !securityOrigin->taintsCanvas(response().url()); |
| 725 } | 727 } |
| 726 | 728 |
| 727 } // namespace blink | 729 } // namespace blink |
| OLD | NEW |