mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-12 04:45:45 +00:00
Bug 548828. Implement HTMLDocument.head. r=bzbarsky
This commit is contained in:
parent
69e0aca09c
commit
cbff1d114e
@ -96,6 +96,7 @@
|
||||
#include "nsIDOMHTMLElement.h"
|
||||
#include "nsIDOMHTMLMapElement.h"
|
||||
#include "nsIDOMHTMLBodyElement.h"
|
||||
#include "nsIDOMHTMLHeadElement.h"
|
||||
#include "nsINameSpaceManager.h"
|
||||
#include "nsGenericHTMLElement.h"
|
||||
#include "nsCSSLoader.h"
|
||||
@ -1641,6 +1642,16 @@ nsHTMLDocument::SetBody(nsIDOMHTMLElement* aBody)
|
||||
return rootElem->AppendChild(aBody, getter_AddRefs(tmp));
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsHTMLDocument::GetHead(nsIDOMHTMLHeadElement** aHead)
|
||||
{
|
||||
*aHead = nsnull;
|
||||
|
||||
Element* head = GetHeadElement();
|
||||
|
||||
return head ? CallQueryInterface(head, aHead) : NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsHTMLDocument::GetImages(nsIDOMHTMLCollection** aImages)
|
||||
{
|
||||
|
@ -194,7 +194,7 @@ public:
|
||||
}
|
||||
|
||||
virtual nsIContent* GetBodyContentExternal();
|
||||
|
||||
|
||||
class nsAutoEditingState {
|
||||
public:
|
||||
nsAutoEditingState(nsHTMLDocument* aDoc, EditingState aState)
|
||||
|
@ -104,6 +104,7 @@ interface nsIDOMEventGroup;
|
||||
interface nsIDOMHTMLElement;
|
||||
interface nsIDOMHTMLFormElement;
|
||||
interface nsIDOMHTMLCollection;
|
||||
interface nsIDOMHTMLHeadElement;
|
||||
|
||||
// CSS
|
||||
interface nsIDOMCSSValue;
|
||||
|
@ -39,7 +39,7 @@
|
||||
|
||||
#include "domstubs.idl"
|
||||
|
||||
[scriptable, uuid(43ac2f64-8a1e-488a-9468-01a2155caf63)]
|
||||
[scriptable, uuid(95cd5ad4-ae8a-4f0e-b168-35e03d5e0b9a)]
|
||||
interface nsIDOMNSHTMLDocument : nsISupports
|
||||
{
|
||||
readonly attribute long width;
|
||||
@ -113,4 +113,6 @@ interface nsIDOMNSHTMLDocument : nsISupports
|
||||
|
||||
// returns the current value of the document or current selection for command
|
||||
DOMString queryCommandValue(in DOMString commandID);
|
||||
|
||||
readonly attribute nsIDOMHTMLHeadElement head;
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user