Closed Bug 846487 Opened 7 years ago Closed 7 years ago

remove some usage of nsIDOMHTMLFooElement

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla22

People

(Reporter: tbsaunde, Assigned: tbsaunde)

Details

Attachments

(4 files)

No description provided.
Attachment #719672 - Flags: review?(Ms2ger)
Comment on attachment 719670 [details] [diff] [review]
remove usage of nsIDOMHTMLTableElement from the tree

Review of attachment 719670 [details] [diff] [review]:
-----------------------------------------------------------------

::: content/html/content/src/HTMLTableElement.cpp
@@ +1211,5 @@
>      NS_IF_ADDREF(mTableInheritedAttributes);
>    }
>  }
>  
> +  void

Indentation is off here.

::: editor/libeditor/html/nsHTMLDataTransfer.cpp
@@ +744,5 @@
>      return NS_OK;
>    }
>  
> +  nsCOMPtr<dom::Element> element = do_QueryInterface(aNode);
> +  if (dom::HTMLTableElement::FromContentOrNull(element)) {

I would just check element->IsHTML(nsGkAtoms::table) here.

::: embedding/components/webbrowserpersist/src/nsWebBrowserPersist.cpp
@@ +2740,5 @@
>          StoreURIAttribute(aNode, "background");
>          return NS_OK;
>      }
>  
> +    if (dom::HTMLTableElement::FromContent(content)) {

Same here

@@ +3032,5 @@
>          }
>          return rv;
>      }
>  
> +    if (dom::HTMLTableElement::FromContent(content)) {

And here
Attachment #719670 - Flags: review?(Ms2ger) → review+
Comment on attachment 719671 [details] [diff] [review]
remove usage of nsIDOMHTMLTableRowElement

Review of attachment 719671 [details] [diff] [review]:
-----------------------------------------------------------------

Same comment about IsHTML().
Attachment #719671 - Flags: review?(Ms2ger) → review+
Comment on attachment 719672 [details] [diff] [review]
remove usage of nsIDOMHTMLBodyElement

Review of attachment 719672 [details] [diff] [review]:
-----------------------------------------------------------------

Same.
Attachment #719672 - Flags: review?(Ms2ger) → review+
Comment on attachment 719673 [details] [diff] [review]
remove remaining nsIDOMHTMLTable stuff

Review of attachment 719673 [details] [diff] [review]:
-----------------------------------------------------------------

Same.
Attachment #719673 - Flags: review?(Ms2ger) → review+
> ::: editor/libeditor/html/nsHTMLDataTransfer.cpp
> @@ +744,5 @@
> >      return NS_OK;
> >    }
> >  
> > +  nsCOMPtr<dom::Element> element = do_QueryInterface(aNode);
> > +  if (dom::HTMLTableElement::FromContentOrNull(element)) {
> 
> I would just check element->IsHTML(nsGkAtoms::table) here.

hm, I guess that works and is nice in that it saves includes, but it sort of feels like this stuff shouldn't need to know that a html table has tag nsGkAtoms::table, but maybe that's just silly abstraction, or maybe this code actually wants to check that the tag is table not that it's type is HTMLTableElement, but in any case I'm not sure what a better way to do this is so ok.
https://hg.mozilla.org/mozilla-central/rev/8668e9339497
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla22
Hey, 
Why were these nsIDOMHTMLFooElement files removed ? 

I no longer have them in the SDK and the only alternative is dom/HTMLFooElement which are for internal use (they need MOZILLA_INTERNAL_API to be defined).

Thanks,
George
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.