diff options
Diffstat (limited to 'components/script')
-rw-r--r-- | components/script/devtools.rs | 2 | ||||
-rw-r--r-- | components/script/dom/bindings/trace.rs | 4 | ||||
-rw-r--r-- | components/script/dom/htmlformelement.rs | 2 | ||||
-rw-r--r-- | components/script/dom/htmliframeelement.rs | 6 | ||||
-rw-r--r-- | components/script/dom/keyboardevent.rs | 2 | ||||
-rw-r--r-- | components/script/dom/mod.rs | 14 | ||||
-rw-r--r-- | components/script/dom/window.rs | 4 | ||||
-rw-r--r-- | components/script/layout_interface.rs | 2 | ||||
-rw-r--r-- | components/script/lib.rs | 3 | ||||
-rw-r--r-- | components/script/page.rs | 6 | ||||
-rw-r--r-- | components/script/script_task.rs | 16 |
11 files changed, 36 insertions, 25 deletions
diff --git a/components/script/devtools.rs b/components/script/devtools.rs index 6c29223af63..e5683d4819a 100644 --- a/components/script/devtools.rs +++ b/components/script/devtools.rs @@ -16,7 +16,7 @@ use dom::window::{ScriptHelpers}; use dom::element::Element; use dom::document::DocumentHelpers; use page::Page; -use servo_msg::constellation_msg::PipelineId; +use msg::constellation_msg::PipelineId; use script_task::get_page; use std::sync::mpsc::Sender; diff --git a/components/script/dom/bindings/trace.rs b/components/script/dom/bindings/trace.rs index e447b4c6a67..5737830994d 100644 --- a/components/script/dom/bindings/trace.rs +++ b/components/script/dom/bindings/trace.rs @@ -48,8 +48,8 @@ use msg::constellation_msg::{PipelineId, SubpageId, WindowSizeData}; use net::image_cache_task::ImageCacheTask; use script_traits::ScriptControlChan; use script_traits::UntrustedNodeAddress; -use servo_msg::compositor_msg::ScriptListener; -use servo_msg::constellation_msg::ConstellationChan; +use msg::compositor_msg::ScriptListener; +use msg::constellation_msg::ConstellationChan; use util::smallvec::{SmallVec1, SmallVec}; use util::str::{LengthOrPercentageOrAuto}; use std::cell::{Cell, RefCell}; diff --git a/components/script/dom/htmlformelement.rs b/components/script/dom/htmlformelement.rs index 74f789ab491..04b1c5019c3 100644 --- a/components/script/dom/htmlformelement.rs +++ b/components/script/dom/htmlformelement.rs @@ -25,7 +25,7 @@ use dom::node::{Node, NodeHelpers, NodeTypeId, document_from_node, window_from_n use hyper::method::Method; use hyper::header::common::ContentType; use hyper::mime; -use servo_msg::constellation_msg::LoadData; +use msg::constellation_msg::LoadData; use util::str::DOMString; use script_task::{ScriptChan, ScriptMsg}; use std::ascii::OwnedAsciiExt; diff --git a/components/script/dom/htmliframeelement.rs b/components/script/dom/htmliframeelement.rs index bb310607b1b..b4f9b577b7b 100644 --- a/components/script/dom/htmliframeelement.rs +++ b/components/script/dom/htmliframeelement.rs @@ -23,9 +23,9 @@ use dom::virtualmethods::VirtualMethods; use dom::window::Window; use page::{IterablePage, Page}; -use servo_msg::constellation_msg::{PipelineId, SubpageId, ConstellationChan}; -use servo_msg::constellation_msg::IFrameSandboxState::{IFrameSandboxed, IFrameUnsandboxed}; -use servo_msg::constellation_msg::Msg as ConstellationMsg; +use msg::constellation_msg::{PipelineId, SubpageId, ConstellationChan}; +use msg::constellation_msg::IFrameSandboxState::{IFrameSandboxed, IFrameUnsandboxed}; +use msg::constellation_msg::Msg as ConstellationMsg; use util::str::DOMString; use string_cache::Atom; diff --git a/components/script/dom/keyboardevent.rs b/components/script/dom/keyboardevent.rs index f220f90a36a..8ff5fe27e63 100644 --- a/components/script/dom/keyboardevent.rs +++ b/components/script/dom/keyboardevent.rs @@ -13,7 +13,7 @@ use dom::bindings::utils::{Reflectable, reflect_dom_object}; use dom::event::{Event, EventTypeId}; use dom::uievent::UIEvent; use dom::window::Window; -use servo_msg::constellation_msg; +use msg::constellation_msg; use util::str::DOMString; use std::borrow::ToOwned; diff --git a/components/script/dom/mod.rs b/components/script/dom/mod.rs index 6a9b4827e96..d5446e525b4 100644 --- a/components/script/dom/mod.rs +++ b/components/script/dom/mod.rs @@ -158,6 +158,20 @@ //! } //! ``` //! +//! Adding a new DOM interface +//! ========================== +//! +//! Adding a new interface `Foo` requires at least the following: +//! +//! * adding the new IDL file at `components/script/dom/webidls/Foo.webidl`; +//! * creating `components/script/dom/foo.rs`; +//! * listing `foo.rs` in components/script/dom/mod.rs`; +//! * defining the DOM struct `Foo` with a `#[dom_struct]` attribute, a +//! superclass or `Reflector` member, and other members as appropriate; +//! * implementing the +//! `dom::bindings::codegen::Bindings::FooBindings::FooMethods` trait for +//! `JSRef<Foo>`. +//! //! Accessing DOM objects from layout //! ================================= //! diff --git a/components/script/dom/window.rs b/components/script/dom/window.rs index ef4d6f14e2d..98947376cc2 100644 --- a/components/script/dom/window.rs +++ b/components/script/dom/window.rs @@ -33,8 +33,8 @@ use script_task::ScriptMsg; use script_traits::ScriptControlChan; use timers::{IsInterval, TimerId, TimerManager, TimerCallback}; -use servo_msg::compositor_msg::ScriptListener; -use servo_msg::constellation_msg::LoadData; +use msg::compositor_msg::ScriptListener; +use msg::constellation_msg::LoadData; use servo_net::image_cache_task::ImageCacheTask; use servo_net::storage_task::StorageTask; use util::str::{DOMString,HTML_SPACE_CHARACTERS}; diff --git a/components/script/layout_interface.rs b/components/script/layout_interface.rs index 416b9c8bee7..ff2f643fd63 100644 --- a/components/script/layout_interface.rs +++ b/components/script/layout_interface.rs @@ -11,7 +11,7 @@ use dom::node::LayoutDataRef; use geom::point::Point2D; use geom::rect::Rect; use script_traits::{ScriptControlChan, OpaqueScriptLayoutChannel, UntrustedNodeAddress}; -use servo_msg::constellation_msg::{PipelineExitType, WindowSizeData}; +use msg::constellation_msg::{PipelineExitType, WindowSizeData}; use util::geometry::Au; use std::any::Any; use std::sync::mpsc::{channel, Receiver, Sender}; diff --git a/components/script/lib.rs b/components/script/lib.rs index 91c22329d0d..b246b5ecda3 100644 --- a/components/script/lib.rs +++ b/components/script/lib.rs @@ -5,8 +5,6 @@ #![feature(unsafe_destructor, plugin, box_syntax, int_uint)] #![deny(unsafe_blocks)] -#![deny(unused_imports)] -#![deny(unused_variables)] #![allow(non_snake_case)] #![allow(missing_copy_implementations)] #![allow(unstable)] @@ -38,7 +36,6 @@ extern crate "net" as servo_net; extern crate util; #[macro_use] extern crate style; -extern crate "msg" as servo_msg; extern crate url; extern crate uuid; extern crate string_cache; diff --git a/components/script/page.rs b/components/script/page.rs index 61de79ff038..44103aae650 100644 --- a/components/script/page.rs +++ b/components/script/page.rs @@ -22,9 +22,9 @@ use script_traits::{UntrustedNodeAddress, ScriptControlChan}; use geom::{Point2D, Rect, Size2D}; use js::rust::Cx; -use servo_msg::compositor_msg::ScriptListener; -use servo_msg::constellation_msg::{ConstellationChan, WindowSizeData}; -use servo_msg::constellation_msg::{PipelineId, SubpageId}; +use msg::compositor_msg::ScriptListener; +use msg::constellation_msg::{ConstellationChan, WindowSizeData}; +use msg::constellation_msg::{PipelineId, SubpageId}; use servo_net::resource_task::ResourceTask; use servo_net::storage_task::StorageTask; use util::geometry::{Au, MAX_RECT}; diff --git a/components/script/script_task.rs b/components/script/script_task.rs index 0f3f5c1b564..438fe67502d 100644 --- a/components/script/script_task.rs +++ b/components/script/script_task.rs @@ -51,14 +51,14 @@ use script_traits::CompositorEvent::{MouseMoveEvent, KeyEvent}; use script_traits::{NewLayoutInfo, OpaqueScriptLayoutChannel}; use script_traits::{ConstellationControlMsg, ScriptControlChan}; use script_traits::ScriptTaskFactory; -use servo_msg::compositor_msg::ReadyState::{FinishedLoading, Loading, PerformingLayout}; -use servo_msg::compositor_msg::{LayerId, ScriptListener}; -use servo_msg::constellation_msg::{ConstellationChan}; -use servo_msg::constellation_msg::{LoadData, NavigationDirection, PipelineId, SubpageId}; -use servo_msg::constellation_msg::{Failure, Msg, WindowSizeData, Key, KeyState}; -use servo_msg::constellation_msg::{KeyModifiers, SUPER, SHIFT, CONTROL, ALT}; -use servo_msg::constellation_msg::{PipelineExitType}; -use servo_msg::constellation_msg::Msg as ConstellationMsg; +use msg::compositor_msg::ReadyState::{FinishedLoading, Loading, PerformingLayout}; +use msg::compositor_msg::{LayerId, ScriptListener}; +use msg::constellation_msg::{ConstellationChan}; +use msg::constellation_msg::{LoadData, NavigationDirection, PipelineId, SubpageId}; +use msg::constellation_msg::{Failure, Msg, WindowSizeData, Key, KeyState}; +use msg::constellation_msg::{KeyModifiers, SUPER, SHIFT, CONTROL, ALT}; +use msg::constellation_msg::{PipelineExitType}; +use msg::constellation_msg::Msg as ConstellationMsg; use servo_net::image_cache_task::ImageCacheTask; use servo_net::resource_task::{ResourceTask, ControlMsg}; use servo_net::resource_task::LoadData as NetLoadData; |