Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(81)

Side by Side Diff: third_party/WebKit/Source/core/html/HTMLObjectElement.h

Issue 2123963003: Add a comment about why HTMLObjectElement inherits FormAssociatedElement (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update comment Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/html/HTMLObjectElement.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. 4 * Copyright (C) 2004, 2006, 2007, 2008, 2009 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 *
(...skipping 13 matching lines...) Expand all
24 #define HTMLObjectElement_h 24 #define HTMLObjectElement_h
25 25
26 #include "core/CoreExport.h" 26 #include "core/CoreExport.h"
27 #include "core/html/FormAssociatedElement.h" 27 #include "core/html/FormAssociatedElement.h"
28 #include "core/html/HTMLPlugInElement.h" 28 #include "core/html/HTMLPlugInElement.h"
29 29
30 namespace blink { 30 namespace blink {
31 31
32 class HTMLFormElement; 32 class HTMLFormElement;
33 33
34 // Inheritance of FormAssociatedElement was used for NPAPI form association, but is still
35 // kept here so that legacy APIs such as form attribute can keep working accordi ng to the spec.
36 // See: https://html.spec.whatwg.org/multipage/embedded-content.html#the-object- element
34 class CORE_EXPORT HTMLObjectElement final : public HTMLPlugInElement, public For mAssociatedElement { 37 class CORE_EXPORT HTMLObjectElement final : public HTMLPlugInElement, public For mAssociatedElement {
35 DEFINE_WRAPPERTYPEINFO(); 38 DEFINE_WRAPPERTYPEINFO();
36 USING_GARBAGE_COLLECTED_MIXIN(HTMLObjectElement); 39 USING_GARBAGE_COLLECTED_MIXIN(HTMLObjectElement);
37 public: 40 public:
38 static HTMLObjectElement* create(Document&, HTMLFormElement*, bool createdBy Parser); 41 static HTMLObjectElement* create(Document&, HTMLFormElement*, bool createdBy Parser);
39 ~HTMLObjectElement() override; 42 ~HTMLObjectElement() override;
40 DECLARE_VIRTUAL_TRACE(); 43 DECLARE_VIRTUAL_TRACE();
41 44
42 const String& classId() const { return m_classId; } 45 const String& classId() const { return m_classId; }
43 46
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 const HTMLObjectElement& objectElement = static_cast<const HTMLObjectElement &>(element); 131 const HTMLObjectElement& objectElement = static_cast<const HTMLObjectElement &>(element);
129 // We need to assert after the cast because FormAssociatedElement doesn't 132 // We need to assert after the cast because FormAssociatedElement doesn't
130 // have hasTagName. 133 // have hasTagName.
131 ASSERT_WITH_SECURITY_IMPLICATION(objectElement.hasTagName(HTMLNames::objectT ag)); 134 ASSERT_WITH_SECURITY_IMPLICATION(objectElement.hasTagName(HTMLNames::objectT ag));
132 return objectElement; 135 return objectElement;
133 } 136 }
134 137
135 } // namespace blink 138 } // namespace blink
136 139
137 #endif // HTMLObjectElement_h 140 #endif // HTMLObjectElement_h
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/html/HTMLObjectElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698