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 * (C) 2000 Stefan Schimanski (1Stein@gmx.de) | 4 * (C) 2000 Stefan Schimanski (1Stein@gmx.de) |
5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011 Apple Inc. All rights
reserved. | 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011 Apple Inc. All rights
reserved. |
6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
7 * | 7 * |
8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
(...skipping 30 matching lines...) Expand all Loading... |
41 #include "core/page/Settings.h" | 41 #include "core/page/Settings.h" |
42 #include "core/plugins/PluginView.h" | 42 #include "core/plugins/PluginView.h" |
43 #include "core/rendering/RenderEmbeddedObject.h" | 43 #include "core/rendering/RenderEmbeddedObject.h" |
44 #include "platform/MIMETypeRegistry.h" | 44 #include "platform/MIMETypeRegistry.h" |
45 #include "platform/Widget.h" | 45 #include "platform/Widget.h" |
46 | 46 |
47 namespace WebCore { | 47 namespace WebCore { |
48 | 48 |
49 using namespace HTMLNames; | 49 using namespace HTMLNames; |
50 | 50 |
51 inline HTMLObjectElement::HTMLObjectElement(const QualifiedName& tagName, Docume
nt& document, HTMLFormElement* form, bool createdByParser) | 51 inline HTMLObjectElement::HTMLObjectElement(Document& document, HTMLFormElement*
form, bool createdByParser) |
52 : HTMLPlugInElement(tagName, document, createdByParser, ShouldNotPreferPlugI
nsForImages) | 52 : HTMLPlugInElement(objectTag, document, createdByParser, ShouldNotPreferPlu
gInsForImages) |
53 , m_useFallbackContent(false) | 53 , m_useFallbackContent(false) |
54 { | 54 { |
55 ASSERT(hasTagName(objectTag)); | |
56 setForm(form ? form : findFormAncestor()); | 55 setForm(form ? form : findFormAncestor()); |
57 ScriptWrappable::init(this); | 56 ScriptWrappable::init(this); |
58 } | 57 } |
59 | 58 |
60 inline HTMLObjectElement::~HTMLObjectElement() | 59 inline HTMLObjectElement::~HTMLObjectElement() |
61 { | 60 { |
62 setForm(0); | 61 setForm(0); |
63 } | 62 } |
64 | 63 |
65 PassRefPtr<HTMLObjectElement> HTMLObjectElement::create(const QualifiedName& tag
Name, Document& document, HTMLFormElement* form, bool createdByParser) | 64 PassRefPtr<HTMLObjectElement> HTMLObjectElement::create(Document& document, HTML
FormElement* form, bool createdByParser) |
66 { | 65 { |
67 return adoptRef(new HTMLObjectElement(tagName, document, form, createdByPars
er)); | 66 return adoptRef(new HTMLObjectElement(document, form, createdByParser)); |
68 } | 67 } |
69 | 68 |
70 RenderWidget* HTMLObjectElement::existingRenderWidget() const | 69 RenderWidget* HTMLObjectElement::existingRenderWidget() const |
71 { | 70 { |
72 return renderPart(); // This will return 0 if the renderer is not a RenderPa
rt. | 71 return renderPart(); // This will return 0 if the renderer is not a RenderPa
rt. |
73 } | 72 } |
74 | 73 |
75 bool HTMLObjectElement::isPresentationAttribute(const QualifiedName& name) const | 74 bool HTMLObjectElement::isPresentationAttribute(const QualifiedName& name) const |
76 { | 75 { |
77 if (name == borderAttr) | 76 if (name == borderAttr) |
(...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
444 { | 443 { |
445 return FormAssociatedElement::form(); | 444 return FormAssociatedElement::form(); |
446 } | 445 } |
447 | 446 |
448 bool HTMLObjectElement::isInteractiveContent() const | 447 bool HTMLObjectElement::isInteractiveContent() const |
449 { | 448 { |
450 return fastHasAttribute(usemapAttr); | 449 return fastHasAttribute(usemapAttr); |
451 } | 450 } |
452 | 451 |
453 } | 452 } |
OLD | NEW |