Bug 827158 - Part 1: Rename nsHTMLObjectElement to mozilla::dom::HTMLObjectElement; r=bzbarsky
authorEhsan Akhgari <ehsan@mozilla.com>
Sun, 06 Jan 2013 13:43:40 -0500
changeset 119003 a28186bf974844a8e7fbbd6ed21395c1c0891177
parent 119002 5bf4b30c71f550f1f809f3a2bddb4d45203a162d
child 119004 0a8c4b6efd8cdeb591504949cd3d0f567797770b
push id21410
push usereakhgari@mozilla.com
push dateWed, 16 Jan 2013 06:16:08 +0000
treeherdermozilla-inbound@0a8c4b6efd8c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbzbarsky
bugs827158
milestone21.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 827158 - Part 1: Rename nsHTMLObjectElement to mozilla::dom::HTMLObjectElement; r=bzbarsky
content/html/content/src/HTMLObjectElement.cpp
content/html/content/src/Makefile.in
content/html/content/src/nsHTMLObjectElement.cpp
rename from content/html/content/src/nsHTMLObjectElement.cpp
rename to content/html/content/src/HTMLObjectElement.cpp
--- a/content/html/content/src/nsHTMLObjectElement.cpp
+++ b/content/html/content/src/HTMLObjectElement.cpp
@@ -19,31 +19,31 @@
 #include "nsIDOMGetSVGDocument.h"
 #include "nsIDOMHTMLObjectElement.h"
 #include "nsFormSubmission.h"
 #include "nsIObjectFrame.h"
 #include "nsNPAPIPluginInstance.h"
 #include "nsIConstraintValidation.h"
 #include "nsIWidget.h"
 
-using namespace mozilla;
-using namespace mozilla::dom;
+namespace mozilla {
+namespace dom {
 
-class nsHTMLObjectElement : public nsGenericHTMLFormElement
-                          , public nsObjectLoadingContent
-                          , public nsIDOMHTMLObjectElement
-                          , public nsIConstraintValidation
-                          , public nsIDOMGetSVGDocument
+class HTMLObjectElement MOZ_FINAL : public nsGenericHTMLFormElement
+                                  , public nsObjectLoadingContent
+                                  , public nsIDOMHTMLObjectElement
+                                  , public nsIConstraintValidation
+                                  , public nsIDOMGetSVGDocument
 {
 public:
   using nsIConstraintValidation::GetValidationMessage;
 
-  nsHTMLObjectElement(already_AddRefed<nsINodeInfo> aNodeInfo,
-                      mozilla::dom::FromParser aFromParser = mozilla::dom::NOT_FROM_PARSER);
-  virtual ~nsHTMLObjectElement();
+  HTMLObjectElement(already_AddRefed<nsINodeInfo> aNodeInfo,
+                    FromParser aFromParser = NOT_FROM_PARSER);
+  virtual ~HTMLObjectElement();
 
   // nsISupports
   NS_DECL_ISUPPORTS_INHERITED
 
   // nsIDOMNode
   NS_FORWARD_NSIDOMNODE_TO_NSINODE
 
   // nsIDOMElement
@@ -101,17 +101,17 @@ public:
   virtual uint32_t GetCapabilities() const;
 
   virtual nsresult Clone(nsINodeInfo *aNodeInfo, nsINode **aResult) const;
 
   nsresult CopyInnerTo(Element* aDest);
 
   void StartObjectLoad() { StartObjectLoad(true); }
 
-  NS_DECL_CYCLE_COLLECTION_CLASS_INHERITED_NO_UNLINK(nsHTMLObjectElement,
+  NS_DECL_CYCLE_COLLECTION_CLASS_INHERITED_NO_UNLINK(HTMLObjectElement,
                                                      nsGenericHTMLFormElement)
 
   virtual nsXPCClassInfo* GetClassInfo();
 
   virtual nsIDOMNode* AsDOMNode() { return this; }
 private:
   /**
    * Calls LoadObject with the correct arguments to start the plugin load.
@@ -125,117 +125,111 @@ private:
   bool IsFocusableForTabIndex();
   
   virtual void GetItemValueText(nsAString& text);
   virtual void SetItemValueText(const nsAString& text);
 
   bool mIsDoneAddingChildren;
 };
 
-
-NS_IMPL_NS_NEW_HTML_ELEMENT_CHECK_PARSER(Object)
-
-
-nsHTMLObjectElement::nsHTMLObjectElement(already_AddRefed<nsINodeInfo> aNodeInfo,
-                                         FromParser aFromParser)
+HTMLObjectElement::HTMLObjectElement(already_AddRefed<nsINodeInfo> aNodeInfo,
+                                     FromParser aFromParser)
   : nsGenericHTMLFormElement(aNodeInfo),
     mIsDoneAddingChildren(!aFromParser)
 {
   RegisterFreezableElement();
   SetIsNetworkCreated(aFromParser == FROM_PARSER_NETWORK);
 
   // <object> is always barred from constraint validation.
   SetBarredFromConstraintValidation(true);
 
   // By default we're in the loading state
   AddStatesSilently(NS_EVENT_STATE_LOADING);
 }
 
-nsHTMLObjectElement::~nsHTMLObjectElement()
+HTMLObjectElement::~HTMLObjectElement()
 {
   UnregisterFreezableElement();
   DestroyImageLoadingContent();
 }
 
 bool
-nsHTMLObjectElement::IsDoneAddingChildren()
+HTMLObjectElement::IsDoneAddingChildren()
 {
   return mIsDoneAddingChildren;
 }
 
 void
-nsHTMLObjectElement::DoneAddingChildren(bool aHaveNotified)
+HTMLObjectElement::DoneAddingChildren(bool aHaveNotified)
 {
   mIsDoneAddingChildren = true;
 
   // If we're already in a document, we need to trigger the load
   // Otherwise, BindToTree takes care of that.
   if (IsInDoc()) {
     StartObjectLoad(aHaveNotified);
   }
 }
 
-NS_IMPL_CYCLE_COLLECTION_CLASS(nsHTMLObjectElement)
-NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN_INHERITED(nsHTMLObjectElement,
+NS_IMPL_CYCLE_COLLECTION_CLASS(HTMLObjectElement)
+NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN_INHERITED(HTMLObjectElement,
                                                   nsGenericHTMLFormElement)
   nsObjectLoadingContent::Traverse(tmp, cb);
 NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END
 
-NS_IMPL_ADDREF_INHERITED(nsHTMLObjectElement, Element)
-NS_IMPL_RELEASE_INHERITED(nsHTMLObjectElement, Element)
-
-DOMCI_NODE_DATA(HTMLObjectElement, nsHTMLObjectElement)
+NS_IMPL_ADDREF_INHERITED(HTMLObjectElement, Element)
+NS_IMPL_RELEASE_INHERITED(HTMLObjectElement, Element)
 
-NS_INTERFACE_TABLE_HEAD_CYCLE_COLLECTION_INHERITED(nsHTMLObjectElement)
-  NS_HTML_CONTENT_INTERFACE_TABLE_BEGIN(nsHTMLObjectElement)
-    NS_INTERFACE_TABLE_ENTRY(nsHTMLObjectElement, nsIDOMHTMLObjectElement)
-    NS_INTERFACE_TABLE_ENTRY(nsHTMLObjectElement, imgINotificationObserver)
-    NS_INTERFACE_TABLE_ENTRY(nsHTMLObjectElement, nsIRequestObserver)
-    NS_INTERFACE_TABLE_ENTRY(nsHTMLObjectElement, nsIStreamListener)
-    NS_INTERFACE_TABLE_ENTRY(nsHTMLObjectElement, nsIFrameLoaderOwner)
-    NS_INTERFACE_TABLE_ENTRY(nsHTMLObjectElement, nsIObjectLoadingContent)
-    NS_INTERFACE_TABLE_ENTRY(nsHTMLObjectElement, nsIImageLoadingContent)
-    NS_INTERFACE_TABLE_ENTRY(nsHTMLObjectElement, imgIOnloadBlocker)
-    NS_INTERFACE_TABLE_ENTRY(nsHTMLObjectElement, nsIInterfaceRequestor)
-    NS_INTERFACE_TABLE_ENTRY(nsHTMLObjectElement, nsIChannelEventSink)
-    NS_INTERFACE_TABLE_ENTRY(nsHTMLObjectElement, nsIConstraintValidation)
-    NS_INTERFACE_TABLE_ENTRY(nsHTMLObjectElement, nsIDOMGetSVGDocument)
+NS_INTERFACE_TABLE_HEAD_CYCLE_COLLECTION_INHERITED(HTMLObjectElement)
+  NS_HTML_CONTENT_INTERFACE_TABLE_BEGIN(HTMLObjectElement)
+    NS_INTERFACE_TABLE_ENTRY(HTMLObjectElement, nsIDOMHTMLObjectElement)
+    NS_INTERFACE_TABLE_ENTRY(HTMLObjectElement, imgINotificationObserver)
+    NS_INTERFACE_TABLE_ENTRY(HTMLObjectElement, nsIRequestObserver)
+    NS_INTERFACE_TABLE_ENTRY(HTMLObjectElement, nsIStreamListener)
+    NS_INTERFACE_TABLE_ENTRY(HTMLObjectElement, nsIFrameLoaderOwner)
+    NS_INTERFACE_TABLE_ENTRY(HTMLObjectElement, nsIObjectLoadingContent)
+    NS_INTERFACE_TABLE_ENTRY(HTMLObjectElement, nsIImageLoadingContent)
+    NS_INTERFACE_TABLE_ENTRY(HTMLObjectElement, imgIOnloadBlocker)
+    NS_INTERFACE_TABLE_ENTRY(HTMLObjectElement, nsIInterfaceRequestor)
+    NS_INTERFACE_TABLE_ENTRY(HTMLObjectElement, nsIChannelEventSink)
+    NS_INTERFACE_TABLE_ENTRY(HTMLObjectElement, nsIConstraintValidation)
+    NS_INTERFACE_TABLE_ENTRY(HTMLObjectElement, nsIDOMGetSVGDocument)
   NS_OFFSET_AND_INTERFACE_TABLE_END
-  NS_HTML_CONTENT_INTERFACE_TABLE_TO_MAP_SEGUE(nsHTMLObjectElement,
+  NS_HTML_CONTENT_INTERFACE_TABLE_TO_MAP_SEGUE(HTMLObjectElement,
                                                nsGenericHTMLFormElement)
 NS_HTML_CONTENT_INTERFACE_TABLE_TAIL_CLASSINFO(HTMLObjectElement)
 
-NS_IMPL_ELEMENT_CLONE(nsHTMLObjectElement)
+NS_IMPL_ELEMENT_CLONE(HTMLObjectElement)
 
 // nsIConstraintValidation
-NS_IMPL_NSICONSTRAINTVALIDATION(nsHTMLObjectElement)
+NS_IMPL_NSICONSTRAINTVALIDATION(HTMLObjectElement)
 
 NS_IMETHODIMP
-nsHTMLObjectElement::GetForm(nsIDOMHTMLFormElement **aForm)
+HTMLObjectElement::GetForm(nsIDOMHTMLFormElement **aForm)
 {
   return nsGenericHTMLFormElement::GetForm(aForm);
 }
 
 void
-nsHTMLObjectElement::GetItemValueText(nsAString& aValue)
+HTMLObjectElement::GetItemValueText(nsAString& aValue)
 {
   GetData(aValue);
 }
 
 void
-nsHTMLObjectElement::SetItemValueText(const nsAString& aValue)
+HTMLObjectElement::SetItemValueText(const nsAString& aValue)
 {
   SetData(aValue);
 }
 
 nsresult
-nsHTMLObjectElement::BindToTree(nsIDocument *aDocument,
-                                nsIContent *aParent,
-                                nsIContent *aBindingParent,
-                                bool aCompileEventHandlers)
+HTMLObjectElement::BindToTree(nsIDocument *aDocument,
+                              nsIContent *aParent,
+                              nsIContent *aBindingParent,
+                              bool aCompileEventHandlers)
 {
   nsresult rv = nsGenericHTMLFormElement::BindToTree(aDocument, aParent,
                                                      aBindingParent,
                                                      aCompileEventHandlers);
   NS_ENSURE_SUCCESS(rv, rv);
 
   rv = nsObjectLoadingContent::BindToTree(aDocument, aParent,
                                           aBindingParent,
@@ -244,37 +238,37 @@ nsHTMLObjectElement::BindToTree(nsIDocum
 
   // Don't kick off load from being bound to a plugin document - the plugin
   // document will call nsObjectLoadingContent::InitializeFromChannel() for the
   // initial load.
   nsCOMPtr<nsIPluginDocument> pluginDoc = do_QueryInterface(aDocument);
 
   // If we already have all the children, start the load.
   if (mIsDoneAddingChildren && !pluginDoc) {
-    void (nsHTMLObjectElement::*start)() = &nsHTMLObjectElement::StartObjectLoad;
+    void (HTMLObjectElement::*start)() = &HTMLObjectElement::StartObjectLoad;
     nsContentUtils::AddScriptRunner(NS_NewRunnableMethod(this, start));
   }
 
   return NS_OK;
 }
 
 void
-nsHTMLObjectElement::UnbindFromTree(bool aDeep,
-                                    bool aNullParent)
+HTMLObjectElement::UnbindFromTree(bool aDeep,
+                                  bool aNullParent)
 {
   nsObjectLoadingContent::UnbindFromTree(aDeep, aNullParent);
   nsGenericHTMLFormElement::UnbindFromTree(aDeep, aNullParent);
 }
 
 
 
 nsresult
-nsHTMLObjectElement::SetAttr(int32_t aNameSpaceID, nsIAtom *aName,
-                             nsIAtom *aPrefix, const nsAString &aValue,
-                             bool aNotify)
+HTMLObjectElement::SetAttr(int32_t aNameSpaceID, nsIAtom *aName,
+                           nsIAtom *aPrefix, const nsAString &aValue,
+                           bool aNotify)
 {
   nsresult rv = nsGenericHTMLFormElement::SetAttr(aNameSpaceID, aName, aPrefix,
                                                   aValue, aNotify);
   NS_ENSURE_SUCCESS(rv, rv);
 
   // if aNotify is false, we are coming from the parser or some such place;
   // we'll get bound after all the attributes have been set, so we'll do the
   // object load from BindToTree/DoneAddingChildren.
@@ -286,48 +280,48 @@ nsHTMLObjectElement::SetAttr(int32_t aNa
       aNameSpaceID == kNameSpaceID_None && aName == nsGkAtoms::data) {
     return LoadObject(aNotify, true);
   }
 
   return NS_OK;
 }
 
 nsresult
-nsHTMLObjectElement::UnsetAttr(int32_t aNameSpaceID, nsIAtom* aAttribute,
-                               bool aNotify)
+HTMLObjectElement::UnsetAttr(int32_t aNameSpaceID, nsIAtom* aAttribute,
+                             bool aNotify)
 {
   nsresult rv = nsGenericHTMLFormElement::UnsetAttr(aNameSpaceID,
                                                     aAttribute, aNotify);
   NS_ENSURE_SUCCESS(rv, rv);
 
   // See comment in SetAttr
   if (aNotify && IsInDoc() && mIsDoneAddingChildren &&
       aNameSpaceID == kNameSpaceID_None && aAttribute == nsGkAtoms::data) {
     return LoadObject(aNotify, true);
   }
 
   return NS_OK;
 }
 
 bool
-nsHTMLObjectElement::IsFocusableForTabIndex()
+HTMLObjectElement::IsFocusableForTabIndex()
 {
   nsIDocument* doc = GetCurrentDoc();
   if (!doc || doc->HasFlag(NODE_IS_EDITABLE)) {
     return false;
   }
 
   return IsEditableRoot() ||
          (Type() == eType_Document &&
           nsContentUtils::IsSubDocumentTabbable(this));
 }
 
 bool
-nsHTMLObjectElement::IsHTMLFocusable(bool aWithMouse,
-                                     bool *aIsFocusable, int32_t *aTabIndex)
+HTMLObjectElement::IsHTMLFocusable(bool aWithMouse,
+                                   bool *aIsFocusable, int32_t *aTabIndex)
 {
   // TODO: this should probably be managed directly by IsHTMLFocusable.
   // See bug 597242.
   nsIDocument *doc = GetCurrentDoc();
   if (!doc || doc->HasFlag(NODE_IS_EDITABLE)) {
     if (aTabIndex) {
       GetTabIndex(aTabIndex);
     }
@@ -361,33 +355,33 @@ nsHTMLObjectElement::IsHTMLFocusable(boo
   if (aTabIndex && *aIsFocusable) {
     *aTabIndex = attrVal->GetIntegerValue();
   }
 
   return false;
 }
 
 nsIContent::IMEState
-nsHTMLObjectElement::GetDesiredIMEState()
+HTMLObjectElement::GetDesiredIMEState()
 {
   if (Type() == eType_Plugin) {
     return IMEState(IMEState::PLUGIN);
   }
    
   return nsGenericHTMLFormElement::GetDesiredIMEState();
 }
 
 NS_IMETHODIMP
-nsHTMLObjectElement::Reset()
+HTMLObjectElement::Reset()
 {
   return NS_OK;
 }
 
 NS_IMETHODIMP
-nsHTMLObjectElement::SubmitNamesValues(nsFormSubmission *aFormSubmission)
+HTMLObjectElement::SubmitNamesValues(nsFormSubmission *aFormSubmission)
 {
   nsAutoString name;
   if (!GetAttr(kNameSpaceID_None, nsGkAtoms::name, name)) {
     // No name, don't submit.
 
     return NS_OK;
   }
 
@@ -407,41 +401,41 @@ nsHTMLObjectElement::SubmitNamesValues(n
 
   nsAutoString value;
   nsresult rv = pi->GetFormValue(value);
   NS_ENSURE_SUCCESS(rv, rv);
 
   return aFormSubmission->AddNameValuePair(name, value);
 }
 
-NS_IMPL_STRING_ATTR(nsHTMLObjectElement, Align, align)
-NS_IMPL_STRING_ATTR(nsHTMLObjectElement, Archive, archive)
-NS_IMPL_STRING_ATTR(nsHTMLObjectElement, Border, border)
-NS_IMPL_URI_ATTR_WITH_BASE(nsHTMLObjectElement, Code, code, codebase)
-NS_IMPL_URI_ATTR(nsHTMLObjectElement, CodeBase, codebase)
-NS_IMPL_STRING_ATTR(nsHTMLObjectElement, CodeType, codetype)
-NS_IMPL_URI_ATTR_WITH_BASE(nsHTMLObjectElement, Data, data, codebase)
-NS_IMPL_BOOL_ATTR(nsHTMLObjectElement, Declare, declare)
-NS_IMPL_STRING_ATTR(nsHTMLObjectElement, Height, height)
-NS_IMPL_INT_ATTR(nsHTMLObjectElement, Hspace, hspace)
-NS_IMPL_STRING_ATTR(nsHTMLObjectElement, Name, name)
-NS_IMPL_STRING_ATTR(nsHTMLObjectElement, Standby, standby)
-NS_IMPL_STRING_ATTR(nsHTMLObjectElement, Type, type)
-NS_IMPL_STRING_ATTR(nsHTMLObjectElement, UseMap, usemap)
-NS_IMPL_INT_ATTR(nsHTMLObjectElement, Vspace, vspace)
-NS_IMPL_STRING_ATTR(nsHTMLObjectElement, Width, width)
+NS_IMPL_STRING_ATTR(HTMLObjectElement, Align, align)
+NS_IMPL_STRING_ATTR(HTMLObjectElement, Archive, archive)
+NS_IMPL_STRING_ATTR(HTMLObjectElement, Border, border)
+NS_IMPL_URI_ATTR_WITH_BASE(HTMLObjectElement, Code, code, codebase)
+NS_IMPL_URI_ATTR(HTMLObjectElement, CodeBase, codebase)
+NS_IMPL_STRING_ATTR(HTMLObjectElement, CodeType, codetype)
+NS_IMPL_URI_ATTR_WITH_BASE(HTMLObjectElement, Data, data, codebase)
+NS_IMPL_BOOL_ATTR(HTMLObjectElement, Declare, declare)
+NS_IMPL_STRING_ATTR(HTMLObjectElement, Height, height)
+NS_IMPL_INT_ATTR(HTMLObjectElement, Hspace, hspace)
+NS_IMPL_STRING_ATTR(HTMLObjectElement, Name, name)
+NS_IMPL_STRING_ATTR(HTMLObjectElement, Standby, standby)
+NS_IMPL_STRING_ATTR(HTMLObjectElement, Type, type)
+NS_IMPL_STRING_ATTR(HTMLObjectElement, UseMap, usemap)
+NS_IMPL_INT_ATTR(HTMLObjectElement, Vspace, vspace)
+NS_IMPL_STRING_ATTR(HTMLObjectElement, Width, width)
 
 int32_t
-nsHTMLObjectElement::TabIndexDefault()
+HTMLObjectElement::TabIndexDefault()
 {
   return IsFocusableForTabIndex() ? 0 : -1;
 }
 
 NS_IMETHODIMP
-nsHTMLObjectElement::GetContentDocument(nsIDOMDocument **aContentDocument)
+HTMLObjectElement::GetContentDocument(nsIDOMDocument **aContentDocument)
 {
   NS_ENSURE_ARG_POINTER(aContentDocument);
 
   *aContentDocument = nullptr;
 
   if (!IsInDoc()) {
     return NS_OK;
   }
@@ -451,26 +445,26 @@ nsHTMLObjectElement::GetContentDocument(
   if (!sub_doc) {
     return NS_OK;
   }
 
   return CallQueryInterface(sub_doc, aContentDocument);
 }
 
 NS_IMETHODIMP
-nsHTMLObjectElement::GetSVGDocument(nsIDOMDocument **aResult)
+HTMLObjectElement::GetSVGDocument(nsIDOMDocument **aResult)
 {
   return GetContentDocument(aResult);
 }
 
 bool
-nsHTMLObjectElement::ParseAttribute(int32_t aNamespaceID,
-                                    nsIAtom *aAttribute,
-                                    const nsAString &aValue,
-                                    nsAttrValue &aResult)
+HTMLObjectElement::ParseAttribute(int32_t aNamespaceID,
+                                  nsIAtom *aAttribute,
+                                  const nsAString &aValue,
+                                  nsAttrValue &aResult)
 {
   if (aNamespaceID == kNameSpaceID_None) {
     if (aAttribute == nsGkAtoms::align) {
       return ParseAlignValue(aValue, aResult);
     }
     if (ParseImageAttribute(aAttribute, aValue, aResult)) {
       return true;
     }
@@ -487,71 +481,78 @@ MapAttributesIntoRule(const nsMappedAttr
   nsGenericHTMLFormElement::MapImageAlignAttributeInto(aAttributes, aData);
   nsGenericHTMLFormElement::MapImageBorderAttributeInto(aAttributes, aData);
   nsGenericHTMLFormElement::MapImageMarginAttributeInto(aAttributes, aData);
   nsGenericHTMLFormElement::MapImageSizeAttributesInto(aAttributes, aData);
   nsGenericHTMLFormElement::MapCommonAttributesInto(aAttributes, aData);
 }
 
 NS_IMETHODIMP_(bool)
-nsHTMLObjectElement::IsAttributeMapped(const nsIAtom *aAttribute) const
+HTMLObjectElement::IsAttributeMapped(const nsIAtom *aAttribute) const
 {
   static const MappedAttributeEntry* const map[] = {
     sCommonAttributeMap,
     sImageMarginSizeAttributeMap,
     sImageBorderAttributeMap,
     sImageAlignAttributeMap,
   };
 
   return FindAttributeDependence(aAttribute, map);
 }
 
 
 nsMapRuleToAttributesFunc
-nsHTMLObjectElement::GetAttributeMappingFunction() const
+HTMLObjectElement::GetAttributeMappingFunction() const
 {
   return &MapAttributesIntoRule;
 }
 
 void
-nsHTMLObjectElement::StartObjectLoad(bool aNotify)
+HTMLObjectElement::StartObjectLoad(bool aNotify)
 {
   // BindToTree can call us asynchronously, and we may be removed from the tree
   // in the interim
   if (!IsInDoc() || !OwnerDoc()->IsActive()) {
     return;
   }
 
   LoadObject(aNotify);
   SetIsNetworkCreated(false);
 }
 
 nsEventStates
-nsHTMLObjectElement::IntrinsicState() const
+HTMLObjectElement::IntrinsicState() const
 {
   return nsGenericHTMLFormElement::IntrinsicState() | ObjectState();
 }
 
 uint32_t
-nsHTMLObjectElement::GetCapabilities() const
+HTMLObjectElement::GetCapabilities() const
 {
   return nsObjectLoadingContent::GetCapabilities() | eSupportClassID;
 }
 
 void
-nsHTMLObjectElement::DestroyContent()
+HTMLObjectElement::DestroyContent()
 {
   nsObjectLoadingContent::DestroyContent();
   nsGenericHTMLFormElement::DestroyContent();
 }
 
 nsresult
-nsHTMLObjectElement::CopyInnerTo(Element* aDest)
+HTMLObjectElement::CopyInnerTo(Element* aDest)
 {
   nsresult rv = nsGenericHTMLFormElement::CopyInnerTo(aDest);
   NS_ENSURE_SUCCESS(rv, rv);
 
   if (aDest->OwnerDoc()->IsStaticDocument()) {
-    CreateStaticClone(static_cast<nsHTMLObjectElement*>(aDest));
+    CreateStaticClone(static_cast<HTMLObjectElement*>(aDest));
   }
 
   return rv;
 }
+
+} // namespace dom
+} // namespace mozilla
+
+DOMCI_NODE_DATA(HTMLObjectElement, mozilla::dom::HTMLObjectElement)
+
+NS_IMPL_NS_NEW_HTML_ELEMENT_CHECK_PARSER(Object)
--- a/content/html/content/src/Makefile.in
+++ b/content/html/content/src/Makefile.in
@@ -88,17 +88,17 @@ CPPSRCS		= \
 		nsHTMLLegendElement.cpp \
 		nsHTMLLinkElement.cpp \
 		nsHTMLMapElement.cpp \
 		nsHTMLMenuElement.cpp \
 		nsHTMLMenuItemElement.cpp \
 		nsHTMLMetaElement.cpp \
 		nsHTMLMeterElement.cpp \
 		nsHTMLModElement.cpp \
-		nsHTMLObjectElement.cpp \
+		HTMLObjectElement.cpp \
 		nsHTMLSharedObjectElement.cpp \
 		nsHTMLOptionElement.cpp \
 		nsHTMLOptGroupElement.cpp \
 		nsHTMLOutputElement.cpp \
 		HTMLParagraphElement.cpp \
 		HTMLPreElement.cpp \
 		nsHTMLProgressElement.cpp \
 		HTMLScriptElement.cpp \