mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 813383 - Use firstElementChild/nextElementSibling/lastElementChild instead of firstChild/nextSibling/lastChild when possible. r=felipe
This commit is contained in:
parent
624e33c962
commit
38eea5034f
@ -179,11 +179,11 @@
|
|||||||
<getter><![CDATA[
|
<getter><![CDATA[
|
||||||
// A generator yielding all collapsed chatboxes, in the order in
|
// A generator yielding all collapsed chatboxes, in the order in
|
||||||
// which they should be restored.
|
// which they should be restored.
|
||||||
let child = this.lastChild;
|
let child = this.lastElementChild;
|
||||||
while (child) {
|
while (child) {
|
||||||
if (child.collapsed)
|
if (child.collapsed)
|
||||||
yield child;
|
yield child;
|
||||||
child = child.previousSibling;
|
child = child.previousElementSibling;
|
||||||
}
|
}
|
||||||
]]></getter>
|
]]></getter>
|
||||||
</property>
|
</property>
|
||||||
@ -191,11 +191,11 @@
|
|||||||
<property name="visibleChildren">
|
<property name="visibleChildren">
|
||||||
<getter><![CDATA[
|
<getter><![CDATA[
|
||||||
// A generator yielding all non-collapsed chatboxes.
|
// A generator yielding all non-collapsed chatboxes.
|
||||||
let child = this.firstChild;
|
let child = this.firstElementChild;
|
||||||
while (child) {
|
while (child) {
|
||||||
if (!child.collapsed)
|
if (!child.collapsed)
|
||||||
yield child;
|
yield child;
|
||||||
child = child.nextSibling;
|
child = child.nextElementSibling;
|
||||||
}
|
}
|
||||||
]]></getter>
|
]]></getter>
|
||||||
</property>
|
</property>
|
||||||
@ -359,8 +359,8 @@
|
|||||||
<method name="removeAll">
|
<method name="removeAll">
|
||||||
<body><![CDATA[
|
<body><![CDATA[
|
||||||
this.selectedChat = null;
|
this.selectedChat = null;
|
||||||
while (this.firstChild) {
|
while (this.firstElementChild) {
|
||||||
this._remove(this.firstChild);
|
this._remove(this.firstElementChild);
|
||||||
}
|
}
|
||||||
// and the nub/popup must also die.
|
// and the nub/popup must also die.
|
||||||
this.nub.collapsed = true;
|
this.nub.collapsed = true;
|
||||||
|
Loading…
Reference in New Issue
Block a user