aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/main/layout/construct.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/main/layout/construct.rs')
-rw-r--r--src/components/main/layout/construct.rs6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/components/main/layout/construct.rs b/src/components/main/layout/construct.rs
index 98d33db8d26..4a2dc5a055d 100644
--- a/src/components/main/layout/construct.rs
+++ b/src/components/main/layout/construct.rs
@@ -43,6 +43,7 @@ use style::ComputedValues;
use servo_util::namespace;
use servo_util::url::parse_url;
use servo_util::url::is_image_data;
+use servo_util::str::is_whitespace_not_nbsp;
use extra::url::Url;
use extra::arc::Arc;
@@ -724,10 +725,7 @@ impl<'ln> NodeUtils for ThreadSafeLayoutNode<'ln> {
match self.type_id() {
TextNodeTypeId => {
unsafe {
- if !self.with_text(|text| text.characterdata
- .data
- .chars()
- .all(|c| c.is_whitespace())) {
+ if !self.with_text(|text| is_whitespace_not_nbsp(text.characterdata.data)) {
return false
}