[librsvg: 1/10] css: use the is_element utility method
- From: Federico Mena Quintero <federico src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [librsvg: 1/10] css: use the is_element utility method
- Date: Mon, 16 Mar 2020 23:42:40 +0000 (UTC)
commit 4d48ce0845199b0b05312af7c76db2e5e1dccad4
Author: Paolo Borelli <pborelli gnome org>
Date: Sun Mar 15 19:20:22 2020 +0100
css: use the is_element utility method
rsvg_internals/src/css.rs | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/rsvg_internals/src/css.rs b/rsvg_internals/src/css.rs
index 8bd635b7..40ee8d18 100644
--- a/rsvg_internals/src/css.rs
+++ b/rsvg_internals/src/css.rs
@@ -420,7 +420,7 @@ impl selectors::Element for RsvgElement {
let mut sibling = self.0.previous_sibling();
while let Some(ref sib) = sibling {
- if sib.borrow().get_type() != NodeType::Chars {
+ if sib.is_element() {
return sibling.map(|n| n.into());
}
@@ -435,7 +435,7 @@ impl selectors::Element for RsvgElement {
let mut sibling = self.0.next_sibling();
while let Some(ref sib) = sibling {
- if sib.borrow().get_type() != NodeType::Chars {
+ if sib.is_element() {
return sibling.map(|n| n.into());
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]