зеркало из https://github.com/mozilla/gecko-dev.git
Bug 883604 - Implement NodeFront.isDocumentElement. r=paul
This commit is contained in:
Родитель
d738064908
Коммит
d7a7f0ad5c
|
@ -141,6 +141,11 @@ var NodeActor = protocol.ActorClass({
|
||||||
attrs: this.writeAttrs()
|
attrs: this.writeAttrs()
|
||||||
};
|
};
|
||||||
|
|
||||||
|
if (this.rawNode.ownerDocument &&
|
||||||
|
this.rawNode.ownerDocument.documentElement === this.rawNode) {
|
||||||
|
form.isDocumentElement = true;
|
||||||
|
}
|
||||||
|
|
||||||
if (this.rawNode.nodeValue) {
|
if (this.rawNode.nodeValue) {
|
||||||
// We only include a short version of the value if it's longer than
|
// We only include a short version of the value if it's longer than
|
||||||
// gValueSummaryLength
|
// gValueSummaryLength
|
||||||
|
@ -306,6 +311,8 @@ let NodeFront = protocol.FrontClass(NodeActor, {
|
||||||
get shortValue() this._form.shortValue,
|
get shortValue() this._form.shortValue,
|
||||||
get incompleteValue() !!this._form.incompleteValue,
|
get incompleteValue() !!this._form.incompleteValue,
|
||||||
|
|
||||||
|
get isDocumentElement() !!this._form.isDocumentElement,
|
||||||
|
|
||||||
// doctype properties
|
// doctype properties
|
||||||
get name() this._form.name,
|
get name() this._form.name,
|
||||||
get publicId() this._form.publicId,
|
get publicId() this._form.publicId,
|
||||||
|
|
Загрузка…
Ссылка в новой задаче