mirror of
https://github.com/servo/servo.git
synced 2025-07-22 23:03:42 +01:00
Replaced DOMString constructor by conversion functions.
Replaced DOMString(...) by DOMString::from(...). Replaced ....0 by String::from(...). Removed any uses of .to_owner() in DOMString::from("...").
This commit is contained in:
parent
736323a779
commit
84bde75b42
64 changed files with 256 additions and 254 deletions
|
@ -159,7 +159,7 @@ impl HTMLFormElement {
|
|||
// TODO: Handle browsing contexts
|
||||
// TODO: Handle validation
|
||||
let event = Event::new(GlobalRef::Window(win.r()),
|
||||
DOMString("submit".to_owned()),
|
||||
DOMString::from("submit"),
|
||||
EventBubbles::Bubbles,
|
||||
EventCancelable::Cancelable);
|
||||
event.fire(self.upcast());
|
||||
|
@ -171,7 +171,7 @@ impl HTMLFormElement {
|
|||
// Step 7-8
|
||||
let mut action = submitter.action();
|
||||
if action.is_empty() {
|
||||
action = DOMString(base.serialize());
|
||||
action = DOMString::from(base.serialize());
|
||||
}
|
||||
// TODO: Resolve the url relative to the submitter element
|
||||
// Step 10-15
|
||||
|
@ -283,7 +283,7 @@ impl HTMLFormElement {
|
|||
if prev == '\r' {
|
||||
buf.push('\n');
|
||||
}
|
||||
DOMString(buf)
|
||||
DOMString::from(buf)
|
||||
}
|
||||
|
||||
let mut ret = self.get_unclean_dataset(submitter);
|
||||
|
@ -311,7 +311,7 @@ impl HTMLFormElement {
|
|||
|
||||
let win = window_from_node(self);
|
||||
let event = Event::new(GlobalRef::Window(win.r()),
|
||||
DOMString("reset".to_owned()),
|
||||
DOMString::from("reset"),
|
||||
EventBubbles::Bubbles,
|
||||
EventCancelable::Cancelable);
|
||||
event.fire(self.upcast());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue