| 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) 2003, 2010 Apple Inc. ALl rights reserved. | 4 * Copyright (C) 2003, 2010 Apple Inc. ALl rights reserved. |
| 5 * | 5 * |
| 6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
| 7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
| 8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
| 9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
| 10 * | 10 * |
| 11 * This library is distributed in the hope that it will be useful, | 11 * This library is distributed in the hope that it will be useful, |
| 12 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 12 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | 13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 14 * Library General Public License for more details. | 14 * Library General Public License for more details. |
| 15 * | 15 * |
| 16 * You should have received a copy of the GNU Library General Public License | 16 * You should have received a copy of the GNU Library General Public License |
| 17 * along with this library; see the file COPYING.LIB. If not, write to | 17 * along with this library; see the file COPYING.LIB. If not, write to |
| 18 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | 18 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
| 19 * Boston, MA 02110-1301, USA. | 19 * Boston, MA 02110-1301, USA. |
| 20 * | 20 * |
| 21 */ | 21 */ |
| 22 | 22 |
| 23 #ifndef HTMLStyleElement_h | 23 #ifndef HTMLStyleElement_h |
| 24 #define HTMLStyleElement_h | 24 #define HTMLStyleElement_h |
| 25 | 25 |
| 26 #include "core/dom/IncrementLoadEventDelayCount.h" |
| 26 #include "core/dom/StyleElement.h" | 27 #include "core/dom/StyleElement.h" |
| 27 #include "core/html/HTMLElement.h" | 28 #include "core/html/HTMLElement.h" |
| 29 #include <memory> |
| 28 | 30 |
| 29 namespace blink { | 31 namespace blink { |
| 30 | 32 |
| 31 class HTMLStyleElement; | |
| 32 | |
| 33 template <typename T> | |
| 34 class EventSender; | |
| 35 using StyleEventSender = EventSender<HTMLStyleElement>; | |
| 36 | |
| 37 class CORE_EXPORT HTMLStyleElement final : public HTMLElement, | 33 class CORE_EXPORT HTMLStyleElement final : public HTMLElement, |
| 38 private StyleElement { | 34 private StyleElement { |
| 39 DEFINE_WRAPPERTYPEINFO(); | 35 DEFINE_WRAPPERTYPEINFO(); |
| 40 USING_GARBAGE_COLLECTED_MIXIN(HTMLStyleElement); | 36 USING_GARBAGE_COLLECTED_MIXIN(HTMLStyleElement); |
| 41 | 37 |
| 42 public: | 38 public: |
| 43 static HTMLStyleElement* create(Document&, bool createdByParser); | 39 static HTMLStyleElement* create(Document&, bool createdByParser); |
| 44 ~HTMLStyleElement() override; | 40 ~HTMLStyleElement() override; |
| 45 | 41 |
| 46 using StyleElement::sheet; | 42 using StyleElement::sheet; |
| 47 | 43 |
| 48 bool disabled() const; | 44 bool disabled() const; |
| 49 void setDisabled(bool); | 45 void setDisabled(bool); |
| 50 | 46 |
| 51 void dispatchPendingEvent(StyleEventSender*); | 47 void dispatchPendingEvent(std::unique_ptr<IncrementLoadEventDelayCount>); |
| 52 static void dispatchPendingLoadEvents(); | |
| 53 | 48 |
| 54 DECLARE_VIRTUAL_TRACE(); | 49 DECLARE_VIRTUAL_TRACE(); |
| 55 | 50 |
| 56 private: | 51 private: |
| 57 HTMLStyleElement(Document&, bool createdByParser); | 52 HTMLStyleElement(Document&, bool createdByParser); |
| 58 | 53 |
| 59 // overload from HTMLElement | 54 // overload from HTMLElement |
| 60 void parseAttribute(const QualifiedName&, | 55 void parseAttribute(const QualifiedName&, |
| 61 const AtomicString&, | 56 const AtomicString&, |
| 62 const AtomicString&) override; | 57 const AtomicString&) override; |
| (...skipping 14 matching lines...) Expand all Loading... |
| 77 const AtomicString& media() const override; | 72 const AtomicString& media() const override; |
| 78 const AtomicString& type() const override; | 73 const AtomicString& type() const override; |
| 79 | 74 |
| 80 bool m_firedLoad; | 75 bool m_firedLoad; |
| 81 bool m_loadedSheet; | 76 bool m_loadedSheet; |
| 82 }; | 77 }; |
| 83 | 78 |
| 84 } // namespace blink | 79 } // namespace blink |
| 85 | 80 |
| 86 #endif // HTMLStyleElement_h | 81 #endif // HTMLStyleElement_h |
| OLD | NEW |