From ddef6211b39d0b4927aff02646070f6ebc052eaa Mon Sep 17 00:00:00 2001 From: Anthony Ramine Date: Wed, 9 Jan 2019 13:15:04 +0100 Subject: Move is_image_data to the layout crate It's only used there. --- components/script_layout_interface/lib.rs | 6 ------ 1 file changed, 6 deletions(-) (limited to 'components/script_layout_interface/lib.rs') diff --git a/components/script_layout_interface/lib.rs b/components/script_layout_interface/lib.rs index 162a04168a6..d4e25c1b3c7 100644 --- a/components/script_layout_interface/lib.rs +++ b/components/script_layout_interface/lib.rs @@ -128,12 +128,6 @@ pub struct TrustedNodeAddress(pub *const c_void); #[allow(unsafe_code)] unsafe impl Send for TrustedNodeAddress {} -pub fn is_image_data(uri: &str) -> bool { - static TYPES: &'static [&'static str] = - &["data:image/png", "data:image/gif", "data:image/jpeg"]; - TYPES.iter().any(|&type_| uri.starts_with(type_)) -} - /// Whether the pending image needs to be fetched or is waiting on an existing fetch. pub enum PendingImageState { Unrequested(ServoUrl), -- cgit v1.2.3