| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * Copyright (C) 2004, 2005, 2006, 2007, 2009, 2010 Apple Inc. All rights | 4 * Copyright (C) 2004, 2005, 2006, 2007, 2009, 2010 Apple Inc. All rights |
| 5 * reserved. | 5 * reserved. |
| 6 * | 6 * |
| 7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
| 8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
| 9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
| 10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 84 .shouldBypassMainWorldCSP()) | 84 .shouldBypassMainWorldCSP()) |
| 85 return ImageLoader::BypassMainWorldCSP; | 85 return ImageLoader::BypassMainWorldCSP; |
| 86 return ImageLoader::DoNotBypassMainWorldCSP; | 86 return ImageLoader::DoNotBypassMainWorldCSP; |
| 87 } | 87 } |
| 88 | 88 |
| 89 class ImageLoader::Task { | 89 class ImageLoader::Task { |
| 90 public: | 90 public: |
| 91 static std::unique_ptr<Task> create(ImageLoader* loader, | 91 static std::unique_ptr<Task> create(ImageLoader* loader, |
| 92 UpdateFromElementBehavior updateBehavior, | 92 UpdateFromElementBehavior updateBehavior, |
| 93 ReferrerPolicy referrerPolicy) { | 93 ReferrerPolicy referrerPolicy) { |
| 94 return wrapUnique(new Task(loader, updateBehavior, referrerPolicy)); | 94 return makeUnique<Task>(loader, updateBehavior, referrerPolicy); |
| 95 } | 95 } |
| 96 | 96 |
| 97 Task(ImageLoader* loader, | 97 Task(ImageLoader* loader, |
| 98 UpdateFromElementBehavior updateBehavior, | 98 UpdateFromElementBehavior updateBehavior, |
| 99 ReferrerPolicy referrerPolicy) | 99 ReferrerPolicy referrerPolicy) |
| 100 : m_loader(loader), | 100 : m_loader(loader), |
| 101 m_shouldBypassMainWorldCSP(shouldBypassMainWorldCSP(loader)), | 101 m_shouldBypassMainWorldCSP(shouldBypassMainWorldCSP(loader)), |
| 102 m_updateBehavior(updateBehavior), | 102 m_updateBehavior(updateBehavior), |
| 103 m_weakFactory(this), | 103 m_weakFactory(this), |
| 104 m_referrerPolicy(referrerPolicy) { | 104 m_referrerPolicy(referrerPolicy) { |
| (...skipping 535 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 640 } | 640 } |
| 641 | 641 |
| 642 void ImageLoader::elementDidMoveToNewDocument() { | 642 void ImageLoader::elementDidMoveToNewDocument() { |
| 643 if (m_loadDelayCounter) | 643 if (m_loadDelayCounter) |
| 644 m_loadDelayCounter->documentChanged(m_element->document()); | 644 m_loadDelayCounter->documentChanged(m_element->document()); |
| 645 clearFailedLoadURL(); | 645 clearFailedLoadURL(); |
| 646 setImage(0); | 646 setImage(0); |
| 647 } | 647 } |
| 648 | 648 |
| 649 } // namespace blink | 649 } // namespace blink |
| OLD | NEW |