зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1446533
part 12. Remove nsIDOMCharacterData. r=mystor
MozReview-Commit-ID: KXex3Rjcire
This commit is contained in:
Родитель
8dfe726ebb
Коммит
2f66e620e3
|
@ -68,10 +68,6 @@
|
|||
#include "nsWhitespaceTokenizer.h"
|
||||
#include "nsAttrName.h"
|
||||
|
||||
#ifdef DEBUG
|
||||
#include "nsIDOMCharacterData.h"
|
||||
#endif
|
||||
|
||||
#include "mozilla/Assertions.h"
|
||||
#include "mozilla/BasicEvents.h"
|
||||
#include "mozilla/ErrorResult.h"
|
||||
|
|
|
@ -23,7 +23,6 @@
|
|||
#include "nsICommandManager.h"
|
||||
#include "nsIDocShell.h"
|
||||
#include "nsIDocument.h"
|
||||
#include "nsIDOMCharacterData.h"
|
||||
#include "nsIDOMDocument.h"
|
||||
#include "nsPIDOMWindow.h"
|
||||
#include "nsIEditingSession.h"
|
||||
|
|
|
@ -152,7 +152,7 @@ CharacterData::SetNodeValueInternal(const nsAString& aNodeValue,
|
|||
|
||||
//----------------------------------------------------------------------
|
||||
|
||||
// Implementation of nsIDOMCharacterData
|
||||
// Implementation of CharacterData
|
||||
|
||||
void
|
||||
CharacterData::GetData(nsAString& aData) const
|
||||
|
|
|
@ -23,8 +23,7 @@ Comment::~Comment()
|
|||
{
|
||||
}
|
||||
|
||||
NS_IMPL_ISUPPORTS_INHERITED(Comment, CharacterData, nsIDOMNode,
|
||||
nsIDOMCharacterData)
|
||||
NS_IMPL_ISUPPORTS_INHERITED(Comment, CharacterData, nsIDOMNode)
|
||||
|
||||
bool
|
||||
Comment::IsNodeOfType(uint32_t aFlags) const
|
||||
|
|
|
@ -9,13 +9,13 @@
|
|||
|
||||
#include "mozilla/Attributes.h"
|
||||
#include "mozilla/dom/CharacterData.h"
|
||||
#include "nsIDOMCharacterData.h"
|
||||
#include "nsIDOMNode.h"
|
||||
|
||||
namespace mozilla {
|
||||
namespace dom {
|
||||
|
||||
class Comment final : public CharacterData,
|
||||
public nsIDOMCharacterData
|
||||
public nsIDOMNode
|
||||
{
|
||||
private:
|
||||
void Init()
|
||||
|
@ -42,9 +42,6 @@ public:
|
|||
// nsISupports
|
||||
NS_DECL_ISUPPORTS_INHERITED
|
||||
|
||||
// nsIDOMCharacterData
|
||||
NS_FORWARD_NSIDOMCHARACTERDATA(CharacterData::)
|
||||
|
||||
// nsINode
|
||||
virtual bool IsNodeOfType(uint32_t aFlags) const override;
|
||||
|
||||
|
|
|
@ -69,9 +69,9 @@ bool
|
|||
DocumentType::IsNodeOfType(uint32_t aFlags) const
|
||||
{
|
||||
// Don't claim to be eDATA_NODE since we're just inheriting
|
||||
// CharacterData for convinience. Doctypes aren't really
|
||||
// CharacterData for convenience. Doctypes aren't really
|
||||
// data nodes (they have a null .nodeValue and don't implement
|
||||
// nsIDOMCharacterData)
|
||||
// the DOM CharacterData interface)
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -99,8 +99,7 @@ nsTextNode::~nsTextNode()
|
|||
|
||||
// Use the CC variant of this, even though this class does not define
|
||||
// a new CC participant, to make QIing to the CC interfaces faster.
|
||||
NS_IMPL_ISUPPORTS_CYCLE_COLLECTION_INHERITED(nsTextNode, CharacterData, nsIDOMNode,
|
||||
nsIDOMCharacterData)
|
||||
NS_IMPL_ISUPPORTS_CYCLE_COLLECTION_INHERITED(nsTextNode, CharacterData, nsIDOMNode)
|
||||
|
||||
JSObject*
|
||||
nsTextNode::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
|
||||
#include "mozilla/Attributes.h"
|
||||
#include "mozilla/dom/Text.h"
|
||||
#include "nsIDOMCharacterData.h"
|
||||
#include "nsIDOMNode.h"
|
||||
#include "nsDebug.h"
|
||||
|
||||
class nsNodeInfoManager;
|
||||
|
@ -22,7 +22,7 @@ class nsNodeInfoManager;
|
|||
* Class used to implement DOM text nodes
|
||||
*/
|
||||
class nsTextNode : public mozilla::dom::Text,
|
||||
public nsIDOMCharacterData
|
||||
public nsIDOMNode
|
||||
{
|
||||
private:
|
||||
void Init()
|
||||
|
@ -47,9 +47,6 @@ public:
|
|||
// nsISupports
|
||||
NS_DECL_ISUPPORTS_INHERITED
|
||||
|
||||
// nsIDOMCharacterData
|
||||
NS_FORWARD_NSIDOMCHARACTERDATA(mozilla::dom::CharacterData::)
|
||||
|
||||
// nsINode
|
||||
virtual bool IsNodeOfType(uint32_t aFlags) const override;
|
||||
|
||||
|
|
|
@ -51,8 +51,7 @@ function testComment(aText)
|
|||
var types = [ Comment, CharacterData, Node ];
|
||||
checkTypes(comment, "comment", types);
|
||||
|
||||
var interfaces = [ "nsIDOMCharacterData", "nsIDOMNode",
|
||||
"nsIDOMEventTarget" ];
|
||||
var interfaces = [ "nsIDOMNode", "nsIDOMEventTarget" ];
|
||||
checkInterfaces(comment, "comment", interfaces);
|
||||
|
||||
testCharacterData(comment, aText);
|
||||
|
|
|
@ -75,8 +75,7 @@ function testComment(aText)
|
|||
var types = [ Comment, CharacterData, Node ];
|
||||
checkTypes(comment, "comment", types);
|
||||
|
||||
var interfaces = [ "nsIDOMCharacterData", "nsIDOMNode",
|
||||
"nsIDOMEventTarget" ];
|
||||
var interfaces = [ "nsIDOMNode", "nsIDOMEventTarget" ];
|
||||
checkInterfaces(comment, "comment", interfaces);
|
||||
|
||||
testCharacterData(comment, aText);
|
||||
|
@ -94,8 +93,7 @@ function testCDATASection(aText, aShouldSucceed)
|
|||
var types = [ CDATASection, CharacterData, Node ];
|
||||
checkTypes(cdataSection, "CDATA section", types);
|
||||
|
||||
var interfaces = [ "nsIDOMCharacterData",
|
||||
"nsIDOMNode", "nsIDOMEventTarget" ];
|
||||
var interfaces = [ "nsIDOMNode", "nsIDOMEventTarget" ];
|
||||
checkInterfaces(cdataSection, "CDATA section", interfaces);
|
||||
|
||||
testCharacterData(cdataSection, aText);
|
||||
|
|
|
@ -17,7 +17,6 @@ const nsIDOMSerializer = I.nsIDOMSerializer;
|
|||
const nsIDOMDocument = I.nsIDOMDocument;
|
||||
const nsIDOMElement = I.nsIDOMElement;
|
||||
const nsIDOMNode = I.nsIDOMNode;
|
||||
const nsIDOMCharacterData = I.nsIDOMCharacterData;
|
||||
const nsIDOMNodeList = I.nsIDOMNodeList;
|
||||
const nsIDOMXULElement = I.nsIDOMXULElement;
|
||||
|
||||
|
|
|
@ -14,7 +14,6 @@
|
|||
#include "nsEditorCID.h"
|
||||
#include "nsLayoutCID.h"
|
||||
#include "nsITextControlFrame.h"
|
||||
#include "nsIDOMCharacterData.h"
|
||||
#include "nsIDOMDocument.h"
|
||||
#include "nsContentCreatorFunctions.h"
|
||||
#include "nsTextControlFrame.h"
|
||||
|
|
|
@ -16,7 +16,6 @@ typedef double DOMHighResTimeStamp;
|
|||
typedef unsigned long long nsViewID;
|
||||
|
||||
// Core
|
||||
interface nsIDOMCharacterData;
|
||||
interface nsIDOMDocument;
|
||||
interface nsIDOMDocumentFragment;
|
||||
interface nsIDOMElement;
|
||||
|
|
|
@ -8,7 +8,6 @@ with Files("**"):
|
|||
BUG_COMPONENT = ("Core", "DOM")
|
||||
|
||||
XPIDL_SOURCES += [
|
||||
'nsIDOMCharacterData.idl',
|
||||
'nsIDOMDocument.idl',
|
||||
'nsIDOMDocumentFragment.idl',
|
||||
'nsIDOMDOMException.idl',
|
||||
|
|
|
@ -1,19 +0,0 @@
|
|||
/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
#include "nsIDOMNode.idl"
|
||||
|
||||
/**
|
||||
* The nsIDOMCharacterData interface extends nsIDOMNode with a set of
|
||||
* attributes and methods for accessing character data in the DOM.
|
||||
*
|
||||
* For more information on this interface please see
|
||||
* http://www.w3.org/TR/DOM-Level-2-Core/
|
||||
*/
|
||||
|
||||
[uuid(4109a2d2-e7af-445d-bb72-c7c9b875f35e)]
|
||||
interface nsIDOMCharacterData : nsIDOMNode
|
||||
{
|
||||
};
|
|
@ -15,8 +15,7 @@ CDATASection::~CDATASection()
|
|||
{
|
||||
}
|
||||
|
||||
NS_IMPL_ISUPPORTS_INHERITED(CDATASection, CharacterData, nsIDOMNode,
|
||||
nsIDOMCharacterData)
|
||||
NS_IMPL_ISUPPORTS_INHERITED(CDATASection, CharacterData, nsIDOMNode)
|
||||
|
||||
JSObject*
|
||||
CDATASection::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
|
||||
|
|
|
@ -9,13 +9,13 @@
|
|||
|
||||
#include "mozilla/Attributes.h"
|
||||
#include "mozilla/dom/Text.h"
|
||||
#include "nsIDOMCharacterData.h"
|
||||
#include "nsIDOMNode.h"
|
||||
|
||||
namespace mozilla {
|
||||
namespace dom {
|
||||
|
||||
class CDATASection final : public Text,
|
||||
public nsIDOMCharacterData
|
||||
public nsIDOMNode
|
||||
{
|
||||
private:
|
||||
void Init()
|
||||
|
@ -44,9 +44,6 @@ public:
|
|||
// nsISupports
|
||||
NS_DECL_ISUPPORTS_INHERITED
|
||||
|
||||
// nsIDOMCharacterData
|
||||
NS_FORWARD_NSIDOMCHARACTERDATA(CharacterData::)
|
||||
|
||||
// nsINode
|
||||
virtual bool IsNodeOfType(uint32_t aFlags) const override;
|
||||
|
||||
|
|
|
@ -62,8 +62,7 @@ ProcessingInstruction::~ProcessingInstruction()
|
|||
{
|
||||
}
|
||||
|
||||
NS_IMPL_ISUPPORTS_INHERITED(ProcessingInstruction, CharacterData,
|
||||
nsIDOMNode, nsIDOMCharacterData)
|
||||
NS_IMPL_ISUPPORTS_INHERITED(ProcessingInstruction, CharacterData, nsIDOMNode)
|
||||
|
||||
JSObject*
|
||||
ProcessingInstruction::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
|
||||
|
|
|
@ -9,14 +9,14 @@
|
|||
|
||||
#include "mozilla/Attributes.h"
|
||||
#include "mozilla/dom/CharacterData.h"
|
||||
#include "nsIDOMCharacterData.h"
|
||||
#include "nsIDOMNode.h"
|
||||
#include "nsAString.h"
|
||||
|
||||
namespace mozilla {
|
||||
namespace dom {
|
||||
|
||||
class ProcessingInstruction : public CharacterData,
|
||||
public nsIDOMCharacterData
|
||||
public nsIDOMNode
|
||||
{
|
||||
public:
|
||||
ProcessingInstruction(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo,
|
||||
|
@ -25,9 +25,6 @@ public:
|
|||
// nsISupports
|
||||
NS_DECL_ISUPPORTS_INHERITED
|
||||
|
||||
// nsIDOMCharacterData
|
||||
NS_FORWARD_NSIDOMCHARACTERDATA(CharacterData::)
|
||||
|
||||
// nsINode
|
||||
virtual bool IsNodeOfType(uint32_t aFlags) const override;
|
||||
|
||||
|
|
|
@ -51,7 +51,6 @@
|
|||
#include "nsIComboboxControlFrame.h"
|
||||
#include "nsComboboxControlFrame.h"
|
||||
#include "nsIListControlFrame.h"
|
||||
#include "nsIDOMCharacterData.h"
|
||||
#include "nsPlaceholderFrame.h"
|
||||
#include "nsTableRowGroupFrame.h"
|
||||
#include "nsIFormControl.h"
|
||||
|
|
|
@ -19,7 +19,6 @@
|
|||
#include "nsIDocument.h"
|
||||
#include "nsIPresShell.h"
|
||||
#include "nsIDOMDocument.h"
|
||||
#include "nsIDOMCharacterData.h"
|
||||
#ifdef MOZ_OLD_STYLE
|
||||
#include "nsRuleNode.h"
|
||||
#include "nsIStyleRule.h"
|
||||
|
|
|
@ -13,7 +13,6 @@
|
|||
#include "nsIAttribute.h"
|
||||
#include "nsIDOMNode.h"
|
||||
#include "nsIDOMNodeList.h"
|
||||
#include "nsIDOMCharacterData.h"
|
||||
#include "nsBindingManager.h"
|
||||
#include "nsNameSpaceManager.h"
|
||||
#include "nsIDocument.h"
|
||||
|
@ -1206,7 +1205,6 @@ inDOMView::AppendKidsToArray(nsINodeList* aKids,
|
|||
!mShowWhitespaceNodes) {
|
||||
nsCOMPtr<nsIContent> content = do_QueryInterface(kid);
|
||||
auto data = static_cast<dom::CharacterData*>(content.get());
|
||||
NS_ASSERTION(data, "Does not implement nsIDOMCharacterData!");
|
||||
if (InspectorUtils::IsIgnorableWhitespace(*data)) {
|
||||
continue;
|
||||
}
|
||||
|
|
|
@ -7,7 +7,6 @@
|
|||
|
||||
#include "ShimInterfaceInfo.h"
|
||||
|
||||
#include "nsIDOMCharacterData.h"
|
||||
#include "nsIDOMCustomEvent.h"
|
||||
#ifdef MOZ_WEBRTC
|
||||
#include "nsIDOMDataChannel.h"
|
||||
|
@ -46,7 +45,6 @@
|
|||
#include "nsITreeBoxObject.h"
|
||||
#include "nsIWebBrowserPersistable.h"
|
||||
|
||||
#include "mozilla/dom/CharacterDataBinding.h"
|
||||
#include "mozilla/dom/CSSPrimitiveValueBinding.h"
|
||||
#include "mozilla/dom/CSSStyleDeclarationBinding.h"
|
||||
#include "mozilla/dom/CSSStyleSheetBinding.h"
|
||||
|
@ -157,7 +155,6 @@ struct ComponentsInterfaceShimEntry {
|
|||
|
||||
const ComponentsInterfaceShimEntry kComponentsInterfaceShimMap[] =
|
||||
{
|
||||
DEFINE_SHIM(CharacterData),
|
||||
DEFINE_SHIM(CustomEvent),
|
||||
DEFINE_SHIM(DOMCursor),
|
||||
DEFINE_SHIM(DOMException),
|
||||
|
|
|
@ -32,7 +32,6 @@
|
|||
#include "nsIWidget.h"
|
||||
#include "nsIWidgetListener.h"
|
||||
|
||||
#include "nsIDOMCharacterData.h"
|
||||
#include "nsINodeList.h"
|
||||
|
||||
#include "nsITimer.h"
|
||||
|
|
Загрузка…
Ссылка в новой задаче