[gxml: 21/25] GomDocument : Update 'query_selector_all' method
- From: Daniel Espinosa Ortiz <despinosa src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gxml: 21/25] GomDocument : Update 'query_selector_all' method
- Date: Tue, 19 Mar 2019 17:47:06 +0000 (UTC)
commit 98d7ef92e06adc7fe382a4b495efa30fa8a77380
Author: BZHDeveloper <inizan yannick gmail com>
Date: Sat Mar 16 18:44:29 2019 +0100
GomDocument : Update 'query_selector_all' method
gxml/GomDocument.vala | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/gxml/GomDocument.vala b/gxml/GomDocument.vala
index 2642aaf..3e2d9ed 100644
--- a/gxml/GomDocument.vala
+++ b/gxml/GomDocument.vala
@@ -356,8 +356,9 @@ public class GXml.GomDocument : GomNode,
var cs = new CssSelectorParser ();
cs.parse (selectors);
var l = new GomNodeList();
- foreach (DomElement e in children) {
- if (cs.match (e))
+ foreach (DomNode e in child_nodes) {
+ if (!(e is DomElement)) continue;
+ if (cs.match (e as DomElement))
l.add (e);
l.add_all (cs.query_selector_all (e));
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]