| 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, 2008, 2010 Apple Inc. All rights reserved. | 4 * Copyright (C) 2004, 2008, 2010 Apple Inc. All rights reserved. |
| 5 * Copyright (C) 2010 Google Inc. All rights reserved. | 5 * Copyright (C) 2010 Google Inc. All rights 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 28 matching lines...) Expand all Loading... |
| 39 class HTMLFormElement; | 39 class HTMLFormElement; |
| 40 class ImageCandidate; | 40 class ImageCandidate; |
| 41 class ShadowRoot; | 41 class ShadowRoot; |
| 42 class ImageBitmapOptions; | 42 class ImageBitmapOptions; |
| 43 | 43 |
| 44 class CORE_EXPORT HTMLImageElement final : public HTMLElement, public CanvasImag
eSource, public ImageBitmapSource { | 44 class CORE_EXPORT HTMLImageElement final : public HTMLElement, public CanvasImag
eSource, public ImageBitmapSource { |
| 45 DEFINE_WRAPPERTYPEINFO(); | 45 DEFINE_WRAPPERTYPEINFO(); |
| 46 public: | 46 public: |
| 47 class ViewportChangeListener; | 47 class ViewportChangeListener; |
| 48 | 48 |
| 49 static PassRefPtrWillBeRawPtr<HTMLImageElement> create(Document&); | 49 static RawPtr<HTMLImageElement> create(Document&); |
| 50 static PassRefPtrWillBeRawPtr<HTMLImageElement> create(Document&, HTMLFormEl
ement*, bool createdByParser); | 50 static RawPtr<HTMLImageElement> create(Document&, HTMLFormElement*, bool cre
atedByParser); |
| 51 static PassRefPtrWillBeRawPtr<HTMLImageElement> createForJSConstructor(Docum
ent&); | 51 static RawPtr<HTMLImageElement> createForJSConstructor(Document&); |
| 52 static PassRefPtrWillBeRawPtr<HTMLImageElement> createForJSConstructor(Docum
ent&, int width); | 52 static RawPtr<HTMLImageElement> createForJSConstructor(Document&, int width)
; |
| 53 static PassRefPtrWillBeRawPtr<HTMLImageElement> createForJSConstructor(Docum
ent&, int width, int height); | 53 static RawPtr<HTMLImageElement> createForJSConstructor(Document&, int width,
int height); |
| 54 | 54 |
| 55 ~HTMLImageElement() override; | 55 ~HTMLImageElement() override; |
| 56 DECLARE_VIRTUAL_TRACE(); | 56 DECLARE_VIRTUAL_TRACE(); |
| 57 | 57 |
| 58 int width(); | 58 int width(); |
| 59 int height(); | 59 int height(); |
| 60 | 60 |
| 61 int naturalWidth() const; | 61 int naturalWidth() const; |
| 62 int naturalHeight() const; | 62 int naturalHeight() const; |
| 63 const String& currentSrc() const; | 63 const String& currentSrc() const; |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 155 bool isInteractiveContent() const override; | 155 bool isInteractiveContent() const override; |
| 156 Image* imageContents() override; | 156 Image* imageContents() override; |
| 157 | 157 |
| 158 void resetFormOwner(); | 158 void resetFormOwner(); |
| 159 ImageCandidate findBestFitImageFromPictureParent(); | 159 ImageCandidate findBestFitImageFromPictureParent(); |
| 160 void setBestFitURLAndDPRFromImageCandidate(const ImageCandidate&); | 160 void setBestFitURLAndDPRFromImageCandidate(const ImageCandidate&); |
| 161 HTMLImageLoader& imageLoader() const { return *m_imageLoader; } | 161 HTMLImageLoader& imageLoader() const { return *m_imageLoader; } |
| 162 void notifyViewportChanged(); | 162 void notifyViewportChanged(); |
| 163 void createMediaQueryListIfDoesNotExist(); | 163 void createMediaQueryListIfDoesNotExist(); |
| 164 | 164 |
| 165 OwnPtrWillBeMember<HTMLImageLoader> m_imageLoader; | 165 Member<HTMLImageLoader> m_imageLoader; |
| 166 RefPtrWillBeMember<ViewportChangeListener> m_listener; | 166 Member<ViewportChangeListener> m_listener; |
| 167 WeakPtrWillBeMember<HTMLFormElement> m_form; | 167 Member<HTMLFormElement> m_form; |
| 168 AtomicString m_bestFitImageURL; | 168 AtomicString m_bestFitImageURL; |
| 169 float m_imageDevicePixelRatio; | 169 float m_imageDevicePixelRatio; |
| 170 RefPtrWillBeMember<HTMLSourceElement> m_source; | 170 Member<HTMLSourceElement> m_source; |
| 171 unsigned m_formWasSetByParser : 1; | 171 unsigned m_formWasSetByParser : 1; |
| 172 unsigned m_elementCreatedByParser : 1; | 172 unsigned m_elementCreatedByParser : 1; |
| 173 unsigned m_useFallbackContent : 1; | 173 unsigned m_useFallbackContent : 1; |
| 174 unsigned m_isFallbackImage : 1; | 174 unsigned m_isFallbackImage : 1; |
| 175 | 175 |
| 176 ReferrerPolicy m_referrerPolicy; | 176 ReferrerPolicy m_referrerPolicy; |
| 177 }; | 177 }; |
| 178 | 178 |
| 179 } // namespace blink | 179 } // namespace blink |
| 180 | 180 |
| 181 #endif // HTMLImageElement_h | 181 #endif // HTMLImageElement_h |
| OLD | NEW |