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