aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--components/script/dom/htmloptionscollection.rs9
-rwxr-xr-xcomponents/script/dom/htmlselectelement.rs2
-rw-r--r--components/script/script_thread.rs2
-rw-r--r--components/style/build_gecko.rs10
4 files changed, 12 insertions, 11 deletions
diff --git a/components/script/dom/htmloptionscollection.rs b/components/script/dom/htmloptionscollection.rs
index 2e4ce0f9a37..95478fc30f3 100644
--- a/components/script/dom/htmloptionscollection.rs
+++ b/components/script/dom/htmloptionscollection.rs
@@ -16,6 +16,7 @@ use dom::bindings::str::DOMString;
use dom::element::Element;
use dom::htmlcollection::{CollectionFilter, HTMLCollection};
use dom::htmloptionelement::HTMLOptionElement;
+use dom::htmlselectelement::HTMLSelectElement;
use dom::node::{document_from_node, Node};
use dom::window::Window;
@@ -25,16 +26,16 @@ pub struct HTMLOptionsCollection {
}
impl HTMLOptionsCollection {
- fn new_inherited(root: &Node, filter: Box<CollectionFilter + 'static>) -> HTMLOptionsCollection {
+ fn new_inherited(select: &HTMLSelectElement, filter: Box<CollectionFilter + 'static>) -> HTMLOptionsCollection {
HTMLOptionsCollection {
- collection: HTMLCollection::new_inherited(root, filter),
+ collection: HTMLCollection::new_inherited(select.upcast(), filter),
}
}
- pub fn new(window: &Window, root: &Node, filter: Box<CollectionFilter + 'static>)
+ pub fn new(window: &Window, select: &HTMLSelectElement, filter: Box<CollectionFilter + 'static>)
-> Root<HTMLOptionsCollection>
{
- reflect_dom_object(box HTMLOptionsCollection::new_inherited(root, filter),
+ reflect_dom_object(box HTMLOptionsCollection::new_inherited(select, filter),
window,
HTMLOptionsCollectionBinding::Wrap)
}
diff --git a/components/script/dom/htmlselectelement.rs b/components/script/dom/htmlselectelement.rs
index 25977da8095..84c3aa89927 100755
--- a/components/script/dom/htmlselectelement.rs
+++ b/components/script/dom/htmlselectelement.rs
@@ -243,7 +243,7 @@ impl HTMLSelectElementMethods for HTMLSelectElement {
self.options.or_init(|| {
let window = window_from_node(self);
HTMLOptionsCollection::new(
- &window, self.upcast(), box OptionsFilter)
+ &window, self, box OptionsFilter)
})
}
diff --git a/components/script/script_thread.rs b/components/script/script_thread.rs
index c50011bf19c..fa83eaed631 100644
--- a/components/script/script_thread.rs
+++ b/components/script/script_thread.rs
@@ -1511,7 +1511,7 @@ impl ScriptThread {
let (response_chan, response_port) = channel();
chan.send(message::Msg::PrepareToExit(response_chan)).ok();
debug!("shutting down layout for page {}", id);
- response_port.recv().unwrap();
+ let _ = response_port.recv();
chan.send(message::Msg::ExitNow).ok();
self.constellation_chan.send(ConstellationMsg::PipelineExited(id)).ok();
diff --git a/components/style/build_gecko.rs b/components/style/build_gecko.rs
index 52af2df5a36..15ca0d55c3e 100644
--- a/components/style/build_gecko.rs
+++ b/components/style/build_gecko.rs
@@ -137,15 +137,15 @@ mod bindings {
if cfg!(target_os = "linux") {
builder = builder.clang_arg("-DOS_LINUX=1");
} else if cfg!(target_os = "solaris") {
- builder = builder.clang_arg("-DOS_SOLARIS=1")
+ builder = builder.clang_arg("-DOS_SOLARIS=1");
} else if cfg!(target_os = "dragonfly") {
- builder = builder.clang_arg("-DOS_BSD=1").clang_arg("-DOS_DRAGONFLY=1")
+ builder = builder.clang_arg("-DOS_BSD=1").clang_arg("-DOS_DRAGONFLY=1");
} else if cfg!(target_os = "freebsd") {
- builder = builder.clang_arg("-DOS_BSD=1").clang_arg("-DOS_FREEBSD=1")
+ builder = builder.clang_arg("-DOS_BSD=1").clang_arg("-DOS_FREEBSD=1");
} else if cfg!(target_os = "netbsd") {
- builder = builder.clang_arg("-DOS_BSD=1").clang_arg("-DOS_NETBSD=1")
+ builder = builder.clang_arg("-DOS_BSD=1").clang_arg("-DOS_NETBSD=1");
} else if cfg!(target_os = "openbsd") {
- builder = builder.clang_arg("-DOS_BSD=1").clang_arg("-DOS_OPENBSD=1")
+ builder = builder.clang_arg("-DOS_BSD=1").clang_arg("-DOS_OPENBSD=1");
} else if cfg!(target_os = "macos") {
builder = builder.clang_arg("-DOS_MACOSX=1")
.clang_arg("-stdlib=libc++")