aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/window.rs
diff options
context:
space:
mode:
authorbors-servo <metajack+bors@gmail.com>2014-10-11 07:45:39 -0600
committerbors-servo <metajack+bors@gmail.com>2014-10-11 07:45:39 -0600
commit9dfd5e7fcd2011a411b219e8c45aadc0ecb270bd (patch)
tree766433d45e69aa6d8abfdbd447d59bcda43461e5 /components/script/dom/window.rs
parente048f3f940e124d45b43a53a850177c45907822d (diff)
parentca2d5d328d18878e369dd010236754ae207dab7d (diff)
downloadservo-9dfd5e7fcd2011a411b219e8c45aadc0ecb270bd.tar.gz
servo-9dfd5e7fcd2011a411b219e8c45aadc0ecb270bd.zip
auto merge of #3642 : Manishearth/servo/form-submit, r=jdm
This is missing a lot of parts, so it doesn't really make any real-world form submission work yet. It provides a skeleton on which the missing bits can be filled in. What works: - `<input>` elements except for `type=file` - GET/POST methods - URLencoded `enctype`s (default) - Submission via `<form>.submit()` only Stuff that needs to be done for most simple real-world cases to work: - [Working text input](https://github.com/servo/servo/pull/3585) - Click handlers for `<submit>` - Possibly `<textarea>` support - Support for the other two enctypes (#3649) Todo: - Correctly implement [planned navigation](https://html.spec.whatwg.org/multipage/forms.html#planned-navigation) using `TrustedFormAddress` (#3648) - [Correctly implement form owners.](https://github.com/servo/servo/issues/3553) Requires html5ever and some discussion of the spec. - `<input type=file>` support - Image submit support - Browsing contexts/targets - Support for non-`<input>` controls - Validation (?) - Dirname (?)
Diffstat (limited to 'components/script/dom/window.rs')
-rw-r--r--components/script/dom/window.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/components/script/dom/window.rs b/components/script/dom/window.rs
index 02166f328e4..f3edfc04943 100644
--- a/components/script/dom/window.rs
+++ b/components/script/dom/window.rs
@@ -24,6 +24,7 @@ use script_task::{ExitWindowMsg, FireTimerMsg, ScriptChan, TriggerLoadMsg, Trigg
use script_traits::ScriptControlChan;
use servo_msg::compositor_msg::ScriptListener;
+use servo_msg::constellation_msg::LoadData;
use servo_net::image_cache_task::ImageCacheTask;
use servo_util::str::{DOMString,HTML_SPACE_CHARACTERS};
use servo_util::task::{spawn_named};
@@ -432,7 +433,7 @@ impl<'a> WindowHelpers for JSRef<'a, Window> {
if href.as_slice().starts_with("#") {
script_chan.send(TriggerFragmentMsg(self.page.id, url));
} else {
- script_chan.send(TriggerLoadMsg(self.page.id, url));
+ script_chan.send(TriggerLoadMsg(self.page.id, LoadData::new(url)));
}
}