diff options
author | Matt Brubeck <mbrubeck@limpet.net> | 2015-07-01 09:55:23 -0700 |
---|---|---|
committer | Matt Brubeck <mbrubeck@limpet.net> | 2015-07-01 10:04:53 -0700 |
commit | 13072c7b0c35f661e5c66fbef1951625201e3fc8 (patch) | |
tree | e400e4926cfcb603be254ff7456320967ca4192a /components/script/dom/element.rs | |
parent | efa60d3a24529cc1b99822f2b1204b799bc78bb2 (diff) | |
download | servo-13072c7b0c35f661e5c66fbef1951625201e3fc8.tar.gz servo-13072c7b0c35f661e5c66fbef1951625201e3fc8.zip |
Remove string_cache dependency from util.
Move `namespace::from_domstring` from util to script::dom, because it is used
only in that crate.
Diffstat (limited to 'components/script/dom/element.rs')
-rw-r--r-- | components/script/dom/element.rs | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/components/script/dom/element.rs b/components/script/dom/element.rs index 269a0853654..4ae12d107ad 100644 --- a/components/script/dom/element.rs +++ b/components/script/dom/element.rs @@ -32,7 +32,7 @@ use dom::bindings::error::Error::NoModificationAllowed; use dom::bindings::js::{JS, LayoutJS, MutNullableHeap}; use dom::bindings::js::{Root, RootedReference}; use dom::bindings::trace::RootedVec; -use dom::bindings::utils::{xml_name_type, validate_and_extract}; +use dom::bindings::utils::{namespace_from_domstring, xml_name_type, validate_and_extract}; use dom::bindings::utils::XMLName::InvalidXMLName; use dom::create::create_element; use dom::domrect::DOMRect; @@ -67,7 +67,6 @@ use style::properties::longhands::{self, border_spacing, height}; use style::values::CSSFloat; use style::values::specified::{self, CSSColor, CSSRGBA}; use util::geometry::Au; -use util::namespace; use util::str::{DOMString, LengthOrPercentageOrAuto}; use cssparser::Color; @@ -1203,7 +1202,7 @@ impl<'a> ElementMethods for &'a Element { fn GetAttributeNS(self, namespace: Option<DOMString>, local_name: DOMString) -> Option<DOMString> { - let namespace = &namespace::from_domstring(namespace); + let namespace = &namespace_from_domstring(namespace); self.get_attribute(namespace, &Atom::from_slice(&local_name)) .map(|attr| attr.r().Value()) } @@ -1255,7 +1254,7 @@ impl<'a> ElementMethods for &'a Element { fn RemoveAttributeNS(self, namespace: Option<DOMString>, local_name: DOMString) { - let namespace = namespace::from_domstring(namespace); + let namespace = namespace_from_domstring(namespace); let local_name = Atom::from_slice(&local_name); self.remove_attribute(&namespace, &local_name); } |