servo: Merge #19975 - Kill browserhtml (from paulrouget:killbhtml); r=mbrubeck,emilio
authorPaul Rouget <me@paulrouget.com>
Tue, 13 Feb 2018 04:54:47 -0500
changeset 458589 dfcfef9a322db951210fbf7f86d77badb489b8ca
parent 458588 365a91ab41e21db14bed86a705536bd222bccfcd
child 458590 9878ed59f9a69362e5fb423767560377a8364e9f
push id1683
push usersfraser@mozilla.com
push dateThu, 26 Apr 2018 16:43:40 +0000
treeherdermozilla-release@5af6cb21869d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmbrubeck, emilio
milestone60.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
servo: Merge #19975 - Kill browserhtml (from paulrouget:killbhtml); r=mbrubeck,emilio Fixes https://github.com/servo/servo/issues/19971 Source-Repo: https://github.com/servo/servo Source-Revision: b1d3d6f6324394f0e9f17b027fef24420d829b5c
servo/Cargo.lock
servo/Info.plist
servo/README.md
servo/components/compositing/compositor.rs
servo/components/compositing/compositor_thread.rs
servo/components/compositing/windowing.rs
servo/components/config/opts.rs
servo/components/config/prefs.rs
servo/components/constellation/constellation.rs
servo/components/constellation/pipeline.rs
servo/components/msg/constellation_msg.rs
servo/components/script/Cargo.toml
servo/components/script/dom/bindings/trace.rs
servo/components/script/dom/document.rs
servo/components/script/dom/forcetouchevent.rs
servo/components/script/dom/htmlanchorelement.rs
servo/components/script/dom/htmliframeelement.rs
servo/components/script/dom/htmllinkelement.rs
servo/components/script/dom/mod.rs
servo/components/script/dom/webidls/BrowserElement.webidl
servo/components/script/dom/webidls/ForceTouchEvent.webidl
servo/components/script/dom/webidls/HTMLIFrameElement.webidl
servo/components/script/dom/webidls/Window.webidl
servo/components/script/dom/window.rs
servo/components/script/dom/xmlhttprequest.rs
servo/components/script/lib.rs
servo/components/script/script_thread.rs
servo/components/script_traits/lib.rs
servo/components/script_traits/script_msg.rs
servo/components/servo/lib.rs
servo/ports/servo/Cargo.toml
servo/ports/servo/glutin_app/window.rs
servo/python/servo/command_base.py
servo/python/servo/package_commands.py
servo/python/servo/post_build_commands.py
servo/resources/package-prefs.json
servo/resources/prefs.json
servo/servo-tidy.toml
servo/support/windows/Servo.wxs.mako
--- a/servo/Cargo.lock
+++ b/servo/Cargo.lock
@@ -252,21 +252,16 @@ dependencies = [
 name = "brotli-decompressor"
 version = "1.1.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "alloc-no-stdlib 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
-name = "browserhtml"
-version = "0.1.17"
-source = "git+https://github.com/browserhtml/browserhtml?branch=crate#84913eafd817c92fbb6bdbb8a8f7480baddee3d3"
-
-[[package]]
 name = "byteorder"
 version = "1.2.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "bytes"
 version = "0.3.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -1967,21 +1962,16 @@ name = "ogg_metadata"
 version = "0.4.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "ogg 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
-name = "open"
-version = "1.2.0"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-
-[[package]]
 name = "openssl"
 version = "0.9.22"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "bitflags 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "foreign-types 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -2371,17 +2361,16 @@ dependencies = [
  "mime 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "mime_guess 1.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "mitochondria 1.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "mozjs 0.1.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "msg 0.0.1",
  "net_traits 0.0.1",
  "num-traits 0.1.37 (registry+https://github.com/rust-lang/crates.io-index)",
  "offscreen_gl_context 0.14.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "open 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "parking_lot 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "phf 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "phf_codegen 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "phf_shared 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "profile_traits 0.0.1",
  "ref_filter_map 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "ref_slice 1.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "regex 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -2564,17 +2553,16 @@ dependencies = [
 
 [[package]]
 name = "servo"
 version = "0.0.1"
 dependencies = [
  "android_injected_glue 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "backtrace 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "browserhtml 0.1.17 (git+https://github.com/browserhtml/browserhtml?branch=crate)",
  "compositing 0.0.1",
  "euclid 0.16.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "gdi32-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "gleam 0.4.20 (registry+https://github.com/rust-lang/crates.io-index)",
  "libservo 0.0.1",
  "log 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "msg 0.0.1",
  "net_traits 0.0.1",
@@ -3527,17 +3515,16 @@ dependencies = [
 "checksum bitreader 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "80b13e2ab064ff3aa0bdbf1eff533f9822dc37899821f5f98c67f263eab51707"
 "checksum block 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "0d8c1fef690941d3e7788d328517591fecc684c084084702d6ff1641e993699a"
 "checksum blurdroid 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "d7daba519d29beebfc7d302795af88a16b43f431b9b268586926ac61cc655a68"
 "checksum blurmac 0.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "72af3718b3f652fb2026bf9d9dd5f92332cd287884283c343f03fff16cbb0172"
 "checksum blurmock 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "68dd72da3a3bb40f3d3bdd366c4cf8e2b1d208c366304f382c80cef8126ca8da"
 "checksum blurz 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "e73bda0f4c71c63a047351070097f3f507e6718e86b9ee525173371ef7b94b73"
 "checksum brotli 1.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "fe87b40996b84fdc56e57c165d93079f4b50cb806598118e692ddfaa3d3c57c0"
 "checksum brotli-decompressor 1.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "313f4b6cc0b365d6b88eda5aa40175ee34ac6efa9a79e0b3b8202eca90247ba8"
-"checksum browserhtml 0.1.17 (git+https://github.com/browserhtml/browserhtml?branch=crate)" = "<none>"
 "checksum byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "652805b7e73fada9d85e9a6682a4abd490cb52d96aeecc12e33a0de34dfd0d23"
 "checksum bytes 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c129aff112dcc562970abb69e2508b40850dd24c274761bb50fb8a0067ba6c27"
 "checksum caseless 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "8950b075cff75cdabadee97148a8b5816c7cf62e5948a6005b5255d564b42fe7"
 "checksum cc 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "2c674f0870e3dbd4105184ea035acb1c32c8ae69939c9e228d2b11bbfe29efad"
 "checksum cexpr 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "393a5f0088efbe41f9d1fcd062f24e83c278608420e62109feb2c8abee07de7d"
 "checksum cfg-if 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "d4c819a1287eb618df47cc647173c5c4c66ba19d888a6e50d605672aed3140de"
 "checksum cgl 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "86765cb42c2a2c497e142af72517c1b4d7ae5bb2f25dfa77a5c69642f2342d89"
 "checksum chrono 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7c20ebe0b2b08b0aeddba49c609fe7957ba2e33449882cb186a180bc60682fa9"
@@ -3660,17 +3647,16 @@ dependencies = [
 "checksum num-traits 0.1.37 (registry+https://github.com/rust-lang/crates.io-index)" = "e1cbfa3781f3fe73dc05321bed52a06d2d491eaa764c52335cf4399f046ece99"
 "checksum num_cpus 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ca313f1862c7ec3e0dfe8ace9fa91b1d9cb5c84ace3d00f5ec4216238e93c167"
 "checksum objc 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "877f30f37acef6749b1841cceab289707f211aecfc756553cd63976190e6cc2e"
 "checksum objc-foundation 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "1add1b659e36c9607c7aab864a76c7a4c2760cd0cd2e120f3fb8b952c7e22bf9"
 "checksum objc_id 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "e4730aa1c64d722db45f7ccc4113a3e2c465d018de6db4d3e7dfe031e8c8a297"
 "checksum offscreen_gl_context 0.14.3 (registry+https://github.com/rust-lang/crates.io-index)" = "eeb69c6b9fff6f2166af94c72cf6333b8bb883910809a396b53a881fd6b5e913"
 "checksum ogg 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7137bf02687385302f4c0aecd77cfce052b69f5b4ee937be778e125c62f67e30"
 "checksum ogg_metadata 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)" = "fc665717454399cba557c55ad226148996e9266ee291f8a37a98bb2cded0a490"
-"checksum open 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "3478ed1686bd1300c8a981a940abc92b06fac9cbef747f4c668d4e032ff7b842"
 "checksum openssl 0.9.22 (registry+https://github.com/rust-lang/crates.io-index)" = "419ef26bb651d72b6c5a603bcc4e4856a362460e62352dfffa53de91d2e81181"
 "checksum openssl-sys 0.9.22 (registry+https://github.com/rust-lang/crates.io-index)" = "5483bdc56756041ba6aa37c9cb59cc2219f012a2a1377d97ad35556ac6676ee7"
 "checksum ordered-float 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "da12c96037889ae0be29dd2bdd260e5a62a7df24e6466d5a15bb8131c1c200a8"
 "checksum osmesa-src 17.3.1-devel (git+https://github.com/servo/osmesa-src)" = "<none>"
 "checksum osmesa-sys 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "88cfece6e95d2e717e0872a7f53a8684712ad13822a7979bc760b9c77ec0013b"
 "checksum ovr-mobile-sys 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "b7b5f9389b2015f8340f0566c488f3e96735e2e8fd7b85d571832cd274ac2998"
 "checksum owning_ref 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "cdf84f41639e037b484f93433aa3897863b561ed65c6e59c7073d7c561710f37"
 "checksum parking_lot 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)" = "149d8f5b97f3c1133e3cfcd8886449959e856b557ff281e292b733d7c69e005e"
--- a/servo/Info.plist
+++ b/servo/Info.plist
@@ -1,14 +1,14 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
 <plist version="1.0">
 <dict>
 	<key>CFBundleExecutable</key>
-	<string>run-servo</string>
+	<string>servo</string>
 	<key>CFBundleGetInfoString</key>
 	<string>Servo</string>
 	<key>CFBundleIconFile</key>
 	<string>servo.icns</string>
 	<key>CFBundleIdentifier</key>
 	<string>org.servo.Servo</string>
 	<key>CFBundleInfoDictionaryVersion</key>
 	<string>6.0</string>
--- a/servo/README.md
+++ b/servo/README.md
@@ -248,21 +248,16 @@ Run Servo with the command:
 ```sh
 ./servo [url] [arguments] # if you run with nightly build
 ./mach run [url] [arguments] # if you run with mach
 
 # For example
 ./mach run https://www.google.com
 ```
 
-Also, don't miss the info on the [browserhtml page](https://github.com/browserhtml/browserhtml) on how to run the Browser.html
-full tech demo (it provides a more browser-like experience than just browsing a single
-URL with servo).
-
-
 ### Commandline Arguments
 
 - `-p INTERVAL` turns on the profiler and dumps info to the console every
   `INTERVAL` seconds
 - `-s SIZE` sets the tile size for painting; defaults to 512
 - `-z` disables all graphical output; useful for running JS / layout tests
 - `-Z help` displays useful output to debug servo
 
--- a/servo/components/compositing/compositor.rs
+++ b/servo/components/compositing/compositor.rs
@@ -13,20 +13,19 @@ use image::{DynamicImage, ImageFormat, R
 use ipc_channel::ipc::{self, IpcSharedMemory};
 use libc::c_void;
 use msg::constellation_msg::{PipelineId, PipelineIndex, PipelineNamespaceId};
 use net_traits::image::base::{Image, PixelFormat};
 use nonzero::NonZero;
 use profile_traits::time::{self, ProfilerCategory, profile};
 use script_traits::{AnimationState, AnimationTickType, ConstellationMsg, LayoutControlMsg};
 use script_traits::{MouseButton, MouseEventType, ScrollState, TouchEventType, TouchId};
-use script_traits::{TouchpadPressurePhase, UntrustedNodeAddress, WindowSizeData, WindowSizeType};
-use script_traits::CompositorEvent::{MouseMoveEvent, MouseButtonEvent, TouchEvent, TouchpadPressureEvent};
+use script_traits::{UntrustedNodeAddress, WindowSizeData, WindowSizeType};
+use script_traits::CompositorEvent::{MouseMoveEvent, MouseButtonEvent, TouchEvent};
 use servo_config::opts;
-use servo_config::prefs::PREFS;
 use servo_geometry::DeviceIndependentPixel;
 use std::collections::HashMap;
 use std::fs::File;
 use std::rc::Rc;
 use std::sync::mpsc::Sender;
 use std::time::{Duration, Instant};
 use style_traits::{CSSPixel, DevicePixel, PinchZoomFactor};
 use style_traits::cursor::CursorKind;
@@ -859,41 +858,16 @@ impl<Window: WindowMethods> IOCompositor
     }
 
     fn on_touch_cancel(&mut self, identifier: TouchId, point: TypedPoint2D<f32, DevicePixel>) {
         // Send the event to script.
         self.touch_handler.on_touch_cancel(identifier, point);
         self.send_touch_event(TouchEventType::Cancel, identifier, point);
     }
 
-    pub fn on_touchpad_pressure_event(&self,
-                                  point: TypedPoint2D<f32, DevicePixel>,
-                                  pressure: f32,
-                                  phase: TouchpadPressurePhase) {
-        match PREFS.get("dom.forcetouch.enabled").as_boolean() {
-            Some(true) => {},
-            _ => return,
-        }
-
-        let results = self.hit_test_at_point(point);
-        if let Some(item) = results.items.first() {
-            let event = TouchpadPressureEvent(
-                item.point_in_viewport.to_untyped(),
-                pressure,
-                phase,
-                Some(UntrustedNodeAddress(item.tag.0 as *const c_void)),
-            );
-            let pipeline_id = PipelineId::from_webrender(item.pipeline);
-            let msg = ConstellationMsg::ForwardEvent(pipeline_id, event);
-            if let Err(e) = self.constellation_chan.send(msg) {
-                warn!("Sending event to constellation failed ({}).", e);
-            }
-        }
-    }
-
     /// <http://w3c.github.io/touch-events/#mouse-events>
     fn simulate_mouse_click(&mut self, p: TypedPoint2D<f32, DevicePixel>) {
         let button = MouseButton::Left;
         self.dispatch_mouse_window_move_event_class(p);
         self.dispatch_mouse_window_event_class(MouseWindowEvent::MouseDown(button, p));
         self.dispatch_mouse_window_event_class(MouseWindowEvent::MouseUp(button, p));
         self.dispatch_mouse_window_event_class(MouseWindowEvent::Click(button, p));
     }
--- a/servo/components/compositing/compositor_thread.rs
+++ b/servo/components/compositing/compositor_thread.rs
@@ -141,16 +141,18 @@ pub enum EmbedderMsg {
     /// The history state has changed.
     HistoryChanged(TopLevelBrowsingContextId, Vec<LoadData>, usize),
     /// Enter or exit fullscreen
     SetFullscreenState(TopLevelBrowsingContextId, bool),
     /// The load of a page has begun
     LoadStart(TopLevelBrowsingContextId),
     /// The load of a page has completed
     LoadComplete(TopLevelBrowsingContextId),
+    /// A pipeline panicked. First string is the reason, second one is the backtrace.
+    Panic(TopLevelBrowsingContextId, String, Option<String>),
 }
 
 /// Messages from the painting thread and the constellation thread to the compositor thread.
 pub enum Msg {
     /// Requests that the compositor shut down.
     Exit,
 
     /// Informs the compositor that the constellation has completed shutdown.
@@ -232,16 +234,17 @@ impl Debug for EmbedderMsg {
             EmbedderMsg::KeyEvent(..) => write!(f, "KeyEvent"),
             EmbedderMsg::SetCursor(..) => write!(f, "SetCursor"),
             EmbedderMsg::NewFavicon(..) => write!(f, "NewFavicon"),
             EmbedderMsg::HeadParsed(..) => write!(f, "HeadParsed"),
             EmbedderMsg::HistoryChanged(..) => write!(f, "HistoryChanged"),
             EmbedderMsg::SetFullscreenState(..) => write!(f, "SetFullscreenState"),
             EmbedderMsg::LoadStart(..) => write!(f, "LoadStart"),
             EmbedderMsg::LoadComplete(..) => write!(f, "LoadComplete"),
+            EmbedderMsg::Panic(..) => write!(f, "Panic"),
         }
     }
 }
 
 /// Data used to construct a compositor.
 pub struct InitialCompositorState {
     /// A channel to the compositor.
     pub sender: CompositorProxy,
--- a/servo/components/compositing/windowing.rs
+++ b/servo/components/compositing/windowing.rs
@@ -6,17 +6,17 @@
 
 use compositor_thread::EventLoopWaker;
 use euclid::{Point2D, Size2D};
 use euclid::{TypedScale, TypedPoint2D, TypedSize2D};
 use gleam::gl;
 use ipc_channel::ipc::IpcSender;
 use msg::constellation_msg::{Key, KeyModifiers, KeyState, TopLevelBrowsingContextId, TraversalDirection};
 use net_traits::net_error_list::NetError;
-use script_traits::{LoadData, MouseButton, TouchEventType, TouchId, TouchpadPressurePhase};
+use script_traits::{LoadData, MouseButton, TouchEventType, TouchId};
 use servo_geometry::DeviceIndependentPixel;
 use servo_url::ServoUrl;
 use std::fmt::{Debug, Error, Formatter};
 use std::rc::Rc;
 use style_traits::DevicePixel;
 use style_traits::cursor::CursorKind;
 use webrender_api::{DeviceUintSize, DeviceUintRect, ScrollLocation};
 
@@ -45,18 +45,16 @@ pub enum WindowEvent {
     /// It's possible that this should be something like
     /// `CompositorMessageWindowEvent(compositor_thread::Msg)` instead.
     Idle,
     /// Sent when part of the window is marked dirty and needs to be redrawn. Before sending this
     /// message, the window must make the same GL context as in `PrepareRenderingEvent` current.
     Refresh,
     /// Sent when the window is resized.
     Resize,
-    /// Touchpad Pressure
-    TouchpadPressure(TypedPoint2D<f32, DevicePixel>, f32, TouchpadPressurePhase),
     /// Sent when a new URL is to be loaded.
     LoadUrl(TopLevelBrowsingContextId, ServoUrl),
     /// Sent when a mouse hit test is to be performed.
     MouseWindowEventClass(MouseWindowEvent),
     /// Sent when a mouse move.
     MouseWindowMoveEventClass(TypedPoint2D<f32, DevicePixel>),
     /// Touch event: type, identifier, point
     Touch(TouchEventType, TouchId, TypedPoint2D<f32, DevicePixel>),
@@ -89,17 +87,16 @@ pub enum WindowEvent {
 }
 
 impl Debug for WindowEvent {
     fn fmt(&self, f: &mut Formatter) -> Result<(), Error> {
         match *self {
             WindowEvent::Idle => write!(f, "Idle"),
             WindowEvent::Refresh => write!(f, "Refresh"),
             WindowEvent::Resize => write!(f, "Resize"),
-            WindowEvent::TouchpadPressure(..) => write!(f, "TouchpadPressure"),
             WindowEvent::KeyEvent(..) => write!(f, "Key"),
             WindowEvent::LoadUrl(..) => write!(f, "LoadUrl"),
             WindowEvent::MouseWindowEventClass(..) => write!(f, "Mouse"),
             WindowEvent::MouseWindowMoveEventClass(..) => write!(f, "MouseMove"),
             WindowEvent::Touch(..) => write!(f, "Touch"),
             WindowEvent::Scroll(..) => write!(f, "Scroll"),
             WindowEvent::Zoom(..) => write!(f, "Zoom"),
             WindowEvent::PinchZoom(..) => write!(f, "PinchZoom"),
@@ -187,9 +184,12 @@ pub trait WindowMethods {
     /// Return the GL function pointer trait.
     fn gl(&self) -> Rc<gl::Gl>;
 
     /// Set whether the application is currently animating.
     /// Typically, when animations are active, the window
     /// will want to avoid blocking on UI events, and just
     /// run the event loop at the vsync interval.
     fn set_animation_state(&self, _state: AnimationState) {}
+
+    /// Called when a pipeline panics.
+    fn handle_panic(&self, browser_id: TopLevelBrowsingContextId, reason: String, backtrace: Option<String>);
 }
--- a/servo/components/config/opts.rs
+++ b/servo/components/config/opts.rs
@@ -604,17 +604,17 @@ pub fn from_cmdline_args(args: &[String]
     opts.optmulti("Z", "debug",
                   "A comma-separated string of debug options. Pass help to show available options.", "");
     opts.optflag("h", "help", "Print this message");
     opts.optopt("", "resources-path", "Path to find static resources", "/home/servo/resources");
     opts.optopt("", "certificate-path", "Path to find SSL certificates", "/home/servo/resources/certs");
     opts.optopt("", "content-process" , "Run as a content process and connect to the given pipe",
                 "servo-ipc-channel.abcdefg");
     opts.optmulti("", "pref",
-                  "A preference to set to enable", "dom.mozbrowser.enabled");
+                  "A preference to set to enable", "dom.bluetooth.enabled");
     opts.optflag("b", "no-native-titlebar", "Do not use native titlebar");
     opts.optflag("w", "webrender", "Use webrender backend");
     opts.optopt("G", "graphics", "Select graphics backend (gl or es2)", "gl");
     opts.optopt("", "config-dir",
                     "config directory following xdg spec on linux platform", "");
     opts.optflag("v", "version", "Display servo version information");
     opts.optflag("", "unminify-js", "Unminify Javascript");
     opts.optopt("", "profiler-db-user", "Profiler database user", "");
--- a/servo/components/config/prefs.rs
+++ b/servo/components/config/prefs.rs
@@ -223,20 +223,16 @@ impl Preferences {
     pub fn get(&self, name: &str) -> Arc<PrefValue> {
         self.0.read().unwrap().get(name).map_or(Arc::new(PrefValue::Missing), |x| x.value().clone())
     }
 
     pub fn cloned(&self) -> HashMap<String, Pref> {
         self.0.read().unwrap().clone()
     }
 
-    pub fn is_mozbrowser_enabled(&self) -> bool {
-        self.get("dom.mozbrowser.enabled").as_boolean().unwrap_or(false)
-    }
-
     pub fn set(&self, name: &str, value: PrefValue) {
         let mut prefs = self.0.write().unwrap();
         if let Some(pref) = prefs.get_mut(name) {
             pref.set(value);
             return;
         }
         prefs.insert(name.to_owned(), Pref::new(value));
     }
--- a/servo/components/constellation/constellation.rs
+++ b/servo/components/constellation/constellation.rs
@@ -38,34 +38,30 @@
 //! |            | ------prev*--------> |            | <---pipeline*-- |         |
 //! |            | ------next*--------> |            |                 +---------+
 //! |            |                      |            |
 //! |            | <-top_level--------- |            |
 //! |            | <-browsing_context-- |            |
 //! +------------+                      +------------+
 //! ```
 //
-//! Complicating matters, there are also mozbrowser iframes, which are top-level
-//! iframes with a parent.
-//!
 //! The constellation also maintains channels to threads, including:
 //!
 //! * The script and layout threads.
 //! * The graphics compositor.
 //! * The font cache, image cache, and resource manager, which load
 //!   and cache shared fonts, images, or other resources.
 //! * The service worker manager.
 //! * The devtools, debugger and webdriver servers.
 //!
 //! The constellation passes messages between the threads, and updates its state
 //! to track the evolving state of the browsing context tree.
 //!
 //! The constellation acts as a logger, tracking any `warn!` messages from threads,
-//! and converting any `error!` or `panic!` into a crash report, which is filed
-//! using an appropriate `mozbrowsererror` event.
+//! and converting any `error!` or `panic!` into a crash report.
 //!
 //! Since there is only one constellation, and its responsibilities include crash reporting,
 //! it is very important that it does not panic.
 //!
 //! It's also important that the constellation not deadlock. In particular, we need
 //! to be careful that we don't introduce any cycles in the can-block-on relation.
 //! Blocking is typically introduced by `receiver.recv()`, which blocks waiting for the
 //! sender to send some data. Servo tries to achieve deadlock-freedom by using the following
@@ -111,35 +107,35 @@ use event_loop::EventLoop;
 use gfx::font_cache_thread::FontCacheThread;
 use gfx_traits::Epoch;
 use ipc_channel::{Error as IpcError};
 use ipc_channel::ipc::{self, IpcSender, IpcReceiver};
 use ipc_channel::router::ROUTER;
 use itertools::Itertools;
 use layout_traits::LayoutThreadFactory;
 use log::{Log, LogLevel, LogLevelFilter, LogMetadata, LogRecord};
-use msg::constellation_msg::{BrowsingContextId, TopLevelBrowsingContextId, FrameType, PipelineId};
+use msg::constellation_msg::{BrowsingContextId, TopLevelBrowsingContextId, PipelineId};
 use msg::constellation_msg::{Key, KeyModifiers, KeyState};
 use msg::constellation_msg::{PipelineNamespace, PipelineNamespaceId, TraversalDirection};
 use net_traits::{self, IpcSend, FetchResponseMsg, ResourceThreads};
 use net_traits::pub_domains::reg_host;
 use net_traits::request::RequestInit;
 use net_traits::storage_thread::{StorageThreadMsg, StorageType};
 use network_listener::NetworkListener;
 use pipeline::{InitialPipelineState, Pipeline};
 use profile_traits::mem;
 use profile_traits::time;
 use script_traits::{AnimationState, AnimationTickType, CompositorEvent};
 use script_traits::{ConstellationControlMsg, ConstellationMsg as FromCompositorMsg, DiscardBrowsingContext};
 use script_traits::{DocumentActivity, DocumentState, LayoutControlMsg, LoadData};
 use script_traits::{IFrameLoadInfo, IFrameLoadInfoWithData, IFrameSandboxState, TimerSchedulerMsg};
 use script_traits::{LayoutMsg as FromLayoutMsg, ScriptMsg as FromScriptMsg, ScriptThreadFactory};
 use script_traits::{LogEntry, ScriptToConstellationChan, ServiceWorkerMsg, webdriver_msg};
-use script_traits::{MozBrowserErrorType, MozBrowserEvent, WebDriverCommandMsg, WindowSizeData};
-use script_traits::{SWManagerMsg, ScopeThings, UpdatePipelineIdReason, WindowSizeType};
+use script_traits::{SWManagerMsg, ScopeThings, UpdatePipelineIdReason, WebDriverCommandMsg};
+use script_traits::{WindowSizeData, WindowSizeType};
 use serde::{Deserialize, Serialize};
 use servo_config::opts;
 use servo_config::prefs::PREFS;
 use servo_rand::{Rng, SeedableRng, ServoRng, random};
 use servo_remutex::ReentrantMutex;
 use servo_url::{Host, ImmutableOrigin, ServoUrl};
 use std::borrow::ToOwned;
 use std::cmp::Ordering;
@@ -653,17 +649,17 @@ impl<Message, LTF, STF> Constellation<Me
         namespace_id
     }
 
     /// Helper function for creating a pipeline
     fn new_pipeline(&mut self,
                     pipeline_id: PipelineId,
                     browsing_context_id: BrowsingContextId,
                     top_level_browsing_context_id: TopLevelBrowsingContextId,
-                    parent_info: Option<(PipelineId, FrameType)>,
+                    parent_info: Option<PipelineId>,
                     initial_window_size: Option<TypedSize2D<f32, CSSPixel>>,
                     // TODO: we have to provide ownership of the LoadData
                     // here, because it will be send on an ipc channel,
                     // and ipc channels take onership of their data.
                     // https://github.com/servo/ipc-channel/issues/138
                     load_data: LoadData,
                     sandbox: IFrameSandboxState,
                     is_private: bool) {
@@ -685,17 +681,17 @@ impl<Message, LTF, STF> Constellation<Me
                                 .and_then(|weak| weak.upgrade());
                             match event_loop {
                                 None => (None, Some(host)),
                                 Some(event_loop) => (Some(event_loop.clone()), None),
                             }
                         },
                     }
                 } else if let Some(parent) = parent_info
-                        .and_then(|(pipeline_id, _)| self.pipelines.get(&pipeline_id)) {
+                        .and_then(|pipeline_id| self.pipelines.get(&pipeline_id)) {
                     (Some(parent.event_loop.clone()), None)
                 } else if let Some(creator) = load_data.creator_pipeline_id
                         .and_then(|pipeline_id| self.pipelines.get(&pipeline_id)) {
                     (Some(creator.event_loop.clone()), None)
                 } else {
                     (None, None)
                 }
             },
@@ -703,17 +699,17 @@ impl<Message, LTF, STF> Constellation<Me
 
         let resource_threads = if is_private {
             self.private_resource_threads.clone()
         } else {
             self.public_resource_threads.clone()
         };
 
         let parent_visibility = parent_info
-            .and_then(|(parent_pipeline_id, _)| self.pipelines.get(&parent_pipeline_id))
+            .and_then(|parent_pipeline_id| self.pipelines.get(&parent_pipeline_id))
             .map(|pipeline| pipeline.visible);
 
         let prev_visibility = self.browsing_contexts.get(&browsing_context_id)
             .and_then(|browsing_context| self.pipelines.get(&browsing_context.pipeline_id))
             .map(|pipeline| pipeline.visible)
             .or(parent_visibility);
 
         let result = Pipeline::spawn::<Message, LTF, STF>(InitialPipelineState {
@@ -819,22 +815,16 @@ impl<Message, LTF, STF> Constellation<Me
     {
         Box::new(
             self.all_browsing_contexts_iter(top_level_browsing_context_id)
                 .map(|browsing_context| browsing_context.next.iter().rev())
                 .kmerge_by(|a, b| a.instant.cmp(&b.instant) == Ordering::Less)
         )
     }
 
-    /// Is the joint session future empty?
-    fn joint_session_future_is_empty(&self, top_level_browsing_context_id: TopLevelBrowsingContextId) -> bool {
-        self.all_browsing_contexts_iter(top_level_browsing_context_id)
-            .all(|browsing_context| browsing_context.next.is_empty())
-    }
-
     #[cfg(feature = "unstable")]
     /// The joint session past is the merge of the session past of every
     /// browsing_context, sorted reverse chronologically.
     fn joint_session_past<'a>(&'a self, top_level_browsing_context_id: TopLevelBrowsingContextId)
                               -> impl Iterator<Item = &'a SessionHistoryEntry> + 'a
     {
         self.all_browsing_contexts_iter(top_level_browsing_context_id)
             .map(|browsing_context| browsing_context.prev.iter().rev()
@@ -861,36 +851,30 @@ impl<Message, LTF, STF> Constellation<Me
                          *prev_instant = entry.instant;
                          Some((instant, entry))
                      }))
                 .kmerge_by(|a, b| a.0.cmp(&b.0) == Ordering::Greater)
                 .map(|(_, entry)| entry)
         )
     }
 
-    /// Is the joint session past empty?
-    fn joint_session_past_is_empty(&self, top_level_browsing_context_id: TopLevelBrowsingContextId) -> bool {
-        self.all_browsing_contexts_iter(top_level_browsing_context_id)
-            .all(|browsing_context| browsing_context.prev.is_empty())
-    }
-
     /// Create a new browsing context and update the internal bookkeeping.
     fn new_browsing_context(&mut self,
                  browsing_context_id: BrowsingContextId,
                  top_level_id: TopLevelBrowsingContextId,
                  pipeline_id: PipelineId,
                  load_data: LoadData) {
         debug!("Creating new browsing context {}", browsing_context_id);
         let browsing_context = BrowsingContext::new(browsing_context_id, top_level_id, pipeline_id, load_data);
         self.browsing_contexts.insert(browsing_context_id, browsing_context);
 
         // If a child browsing_context, add it to the parent pipeline.
         let parent_info = self.pipelines.get(&pipeline_id)
             .and_then(|pipeline| pipeline.parent_info);
-        if let Some((parent_id, _)) = parent_info {
+        if let Some(parent_id) = parent_info {
             if let Some(parent) = self.pipelines.get_mut(&parent_id) {
                 parent.add_child(browsing_context_id);
             }
         }
     }
 
     fn add_pending_change(&mut self, change: SessionHistoryChange) {
         self.handle_load_start_msg(change.top_level_browsing_context_id, change.new_pipeline_id);
@@ -1168,20 +1152,16 @@ impl<Message, LTF, STF> Constellation<Me
                 } else {
                     warn!("constellation got set final url message for dead pipeline");
                 }
             }
             FromScriptMsg::PostMessage(browsing_context_id, origin, data) => {
                 debug!("constellation got postMessage message");
                 self.handle_post_message_msg(browsing_context_id, origin, data);
             }
-            FromScriptMsg::MozBrowserEvent(pipeline_id, event) => {
-                debug!("constellation got mozbrowser event message");
-                self.handle_mozbrowser_event_msg(pipeline_id, source_top_ctx_id, event);
-            }
             FromScriptMsg::Focus => {
                 debug!("constellation got focus message");
                 self.handle_focus_msg(source_pipeline_id);
             }
             FromScriptMsg::ForwardEvent(destination_pipeline_id, event) => {
                 self.forward_event(destination_pipeline_id, event);
             }
             FromScriptMsg::GetClipboardContents(sender) => {
@@ -1510,18 +1490,17 @@ impl<Message, LTF, STF> Constellation<Me
             println!("Pipeline failed in hard-fail mode.  Crashing!");
             process::exit(1);
         }
 
         debug!("Panic handler for top-level browsing context {}: {}.", top_level_browsing_context_id, reason);
 
         let browsing_context_id = BrowsingContextId::from(top_level_browsing_context_id);
 
-        // Notify the browser chrome that the pipeline has failed
-        self.trigger_mozbrowsererror(top_level_browsing_context_id, reason, backtrace);
+        self.embedder_proxy.send(EmbedderMsg::Panic(top_level_browsing_context_id, reason, backtrace));
 
         let (window_size, pipeline_id) = {
             let browsing_context = self.browsing_contexts.get(&browsing_context_id);
             let window_size = browsing_context.and_then(|browsing_context| browsing_context.size);
             let pipeline_id = browsing_context.map(|browsing_context| browsing_context.pipeline_id);
             (window_size, pipeline_id)
         };
 
@@ -1651,17 +1630,17 @@ impl<Message, LTF, STF> Constellation<Me
 
             self.resize_browsing_context(window_size, WindowSizeType::Initial, browsing_context_id);
         }
     }
 
     fn handle_subframe_loaded(&mut self, pipeline_id: PipelineId) {
         let (browsing_context_id, parent_id) = match self.pipelines.get(&pipeline_id) {
             Some(pipeline) => match pipeline.parent_info {
-                Some((parent_id, _)) => (pipeline.browsing_context_id, parent_id),
+                Some(parent_id) => (pipeline.browsing_context_id, parent_id),
                 None => return debug!("Pipeline {} has no parent.", pipeline_id),
             },
             None => return warn!("Pipeline {} loaded after closure.", pipeline_id),
         };
         let msg = ConstellationControlMsg::DispatchIFrameLoadEvent {
             target: browsing_context_id,
             parent: parent_id,
             child: pipeline_id,
@@ -1727,17 +1706,17 @@ impl<Message, LTF, STF> Constellation<Me
         } else {
             None
         };
 
         // Create the new pipeline, attached to the parent and push to pending changes
         self.new_pipeline(load_info.info.new_pipeline_id,
                           load_info.info.browsing_context_id,
                           load_info.info.top_level_browsing_context_id,
-                          Some((load_info.info.parent_pipeline_id, load_info.info.frame_type)),
+                          Some(load_info.info.parent_pipeline_id),
                           window_size,
                           load_data.clone(),
                           load_info.sandbox,
                           is_private);
         self.add_pending_change(SessionHistoryChange {
             top_level_browsing_context_id: load_info.info.top_level_browsing_context_id,
             browsing_context_id: load_info.info.browsing_context_id,
             new_pipeline_id: load_info.info.new_pipeline_id,
@@ -1747,17 +1726,16 @@ impl<Message, LTF, STF> Constellation<Me
     }
 
     fn handle_script_new_iframe(&mut self,
                                 load_info: IFrameLoadInfo,
                                 layout_sender: IpcSender<LayoutControlMsg>) {
         let IFrameLoadInfo {
             parent_pipeline_id,
             new_pipeline_id,
-            frame_type,
             replace,
             browsing_context_id,
             top_level_browsing_context_id,
             is_private,
         } = load_info;
 
         let url = ServoUrl::parse("about:blank").expect("infallible");
 
@@ -1767,17 +1745,17 @@ impl<Message, LTF, STF> Constellation<Me
                 None => return warn!("Script loaded url in closed iframe {}.", parent_pipeline_id),
             };
 
             let script_sender = parent_pipeline.event_loop.clone();
 
             Pipeline::new(new_pipeline_id,
                           browsing_context_id,
                           top_level_browsing_context_id,
-                          Some((parent_pipeline_id, frame_type)),
+                          Some(parent_pipeline_id),
                           script_sender,
                           layout_sender,
                           self.compositor_proxy.clone(),
                           is_private || parent_pipeline.is_private,
                           url.clone(),
                           parent_pipeline.visible)
         };
 
@@ -1836,37 +1814,21 @@ impl<Message, LTF, STF> Constellation<Me
         };
         if let Err(e) = result {
             self.handle_send_error(pipeline_id, e);
         }
     }
 
     fn handle_alert(&mut self,
                     top_level_browsing_context_id: TopLevelBrowsingContextId,
-                    message: String,
+                    _message: String,
                     sender: IpcSender<bool>) {
-        let browser_pipeline_id = self.browsing_contexts.get(&BrowsingContextId::from(top_level_browsing_context_id))
-            .and_then(|browsing_context| self.pipelines.get(&browsing_context.pipeline_id))
-            .and_then(|pipeline| pipeline.parent_info)
-            .map(|(browser_pipeline_id, _)| browser_pipeline_id);
-        let mozbrowser_modal_prompt = PREFS.is_mozbrowser_enabled() && browser_pipeline_id.is_some();
-
-        if mozbrowser_modal_prompt {
-            // https://developer.mozilla.org/en-US/docs/Web/Events/mozbrowsershowmodalprompt
-            let prompt_type = String::from("alert");
-            let title = String::from("Alert");
-            let return_value = String::from("");
-            let event = MozBrowserEvent::ShowModalPrompt(prompt_type, title, message, return_value);
-            match browser_pipeline_id.and_then(|id| self.pipelines.get(&id)) {
-                None => warn!("Alert sent after browser pipeline closure."),
-                Some(pipeline) => pipeline.trigger_mozbrowser_event(Some(top_level_browsing_context_id), event),
-            }
-        }
-
-        let result = sender.send(!mozbrowser_modal_prompt);
+        // FIXME: forward alert event to embedder
+        // https://github.com/servo/servo/issues/19992
+        let result = sender.send(true);
         if let Err(e) = result {
             let ctx_id = BrowsingContextId::from(top_level_browsing_context_id);
             let pipeline_id = match self.browsing_contexts.get(&ctx_id) {
                 Some(ctx) => ctx.pipeline_id,
                 None => return warn!("Alert sent for unknown browsing context."),
             };
             self.handle_send_error(pipeline_id, e);
         }
@@ -1897,17 +1859,17 @@ impl<Message, LTF, STF> Constellation<Me
         let (browsing_context_id, parent_info) = match self.pipelines.get(&source_id) {
             Some(pipeline) => (pipeline.browsing_context_id, pipeline.parent_info),
             None => {
                 warn!("Pipeline {} loaded after closure.", source_id);
                 return None;
             }
         };
         match parent_info {
-            Some((parent_pipeline_id, _)) => {
+            Some(parent_pipeline_id) => {
                 // Find the script thread for the pipeline containing the iframe
                 // and issue an iframe load through there.
                 let msg = ConstellationControlMsg::Navigate(parent_pipeline_id,
                                                             browsing_context_id,
                                                             load_data,
                                                             replace);
                 let result = match self.pipelines.get(&parent_pipeline_id) {
                     Some(parent_pipeline) => parent_pipeline.event_loop.send(msg),
@@ -2126,32 +2088,16 @@ impl<Message, LTF, STF> Constellation<Me
             Some(pipeline) => pipeline.event_loop.send(msg),
             None => return warn!("postMessage to closed pipeline {}.", pipeline_id),
         };
         if let Err(e) = result {
             self.handle_send_error(pipeline_id, e);
         }
     }
 
-    fn handle_mozbrowser_event_msg(&mut self,
-                                   pipeline_id: PipelineId,
-                                   top_level_browsing_context_id: TopLevelBrowsingContextId,
-                                   event: MozBrowserEvent) {
-        assert!(PREFS.is_mozbrowser_enabled());
-
-        // Find the script channel for the given parent pipeline,
-        // and pass the event to that script thread.
-        // If the pipeline lookup fails, it is because we have torn down the pipeline,
-        // so it is reasonable to silently ignore the event.
-        match self.pipelines.get(&pipeline_id) {
-            Some(pipeline) => pipeline.trigger_mozbrowser_event(Some(top_level_browsing_context_id), event),
-            None => warn!("Pipeline {:?} handling mozbrowser event after closure.", pipeline_id),
-        }
-    }
-
     fn handle_get_pipeline(&mut self,
                            browsing_context_id: BrowsingContextId,
                            resp_chan: IpcSender<Option<PipelineId>>) {
         let current_pipeline_id = self.browsing_contexts.get(&browsing_context_id)
             .map(|browsing_context| browsing_context.pipeline_id);
         let pipeline_id_loaded = self.pending_changes.iter().rev()
             .find(|x| x.browsing_context_id == browsing_context_id)
             .map(|x| x.new_pipeline_id)
@@ -2170,17 +2116,17 @@ impl<Message, LTF, STF> Constellation<Me
         }
     }
 
     fn focus_parent_pipeline(&mut self, pipeline_id: PipelineId) {
         let (browsing_context_id, parent_info) = match self.pipelines.get(&pipeline_id) {
             Some(pipeline) => (pipeline.browsing_context_id, pipeline.parent_info),
             None => return warn!("Pipeline {:?} focus parent after closure.", pipeline_id),
         };
-        let (parent_pipeline_id, _) = match parent_info {
+        let parent_pipeline_id = match parent_info {
             Some(info) => info,
             None => return debug!("Pipeline {:?} focus has no parent.", pipeline_id),
         };
 
         // Send a message to the parent of the provided pipeline (if it exists)
         // telling it to mark the iframe element as focused.
         let msg = ConstellationControlMsg::FocusIFrame(parent_pipeline_id, browsing_context_id);
         let result = match self.pipelines.get(&parent_pipeline_id) {
@@ -2229,17 +2175,17 @@ impl<Message, LTF, STF> Constellation<Me
         }
     }
 
     fn handle_visibility_change_complete(&mut self, pipeline_id: PipelineId, visibility: bool) {
         let (browsing_context_id, parent_pipeline_info) = match self.pipelines.get(&pipeline_id) {
             None => return warn!("Visibity change for closed pipeline {:?}.", pipeline_id),
             Some(pipeline) => (pipeline.browsing_context_id, pipeline.parent_info),
         };
-        if let Some((parent_pipeline_id, _)) = parent_pipeline_info {
+        if let Some(parent_pipeline_id) = parent_pipeline_info {
             let visibility_msg = ConstellationControlMsg::NotifyVisibilityChange(parent_pipeline_id,
                                                                                  browsing_context_id,
                                                                                  visibility);
             let result = match self.pipelines.get(&parent_pipeline_id) {
                 None => return warn!("Parent pipeline {:?} closed", parent_pipeline_id),
                 Some(parent_pipeline) => parent_pipeline.event_loop.send(visibility_msg),
             };
 
@@ -2425,32 +2371,26 @@ impl<Message, LTF, STF> Constellation<Me
         self.update_activity(old_pipeline_id);
         self.update_activity(pipeline_id);
         self.notify_history_changed(top_level_id);
 
         self.update_frame_tree_if_active(top_level_id);
 
         // Update the owning iframe to point to the new pipeline id.
         // This makes things like contentDocument work correctly.
-        if let Some((parent_pipeline_id, frame_type)) = parent_info {
+        if let Some(parent_pipeline_id) = parent_info {
             let msg = ConstellationControlMsg::UpdatePipelineId(parent_pipeline_id,
                 browsing_context_id, pipeline_id, UpdatePipelineIdReason::Traversal);
             let result = match self.pipelines.get(&parent_pipeline_id) {
                 None => return warn!("Pipeline {:?} child traversed after closure.", parent_pipeline_id),
                 Some(pipeline) => pipeline.event_loop.send(msg),
             };
             if let Err(e) = result {
                 self.handle_send_error(parent_pipeline_id, e);
             }
-
-            // If this is a mozbrowser iframe, send a mozbrowser location change event.
-            // This is the result of a back/forward traversal.
-            if frame_type == FrameType::MozBrowserIFrame {
-                self.trigger_mozbrowserlocationchange(top_level_id);
-            }
         }
     }
 
     fn notify_history_changed(&self, top_level_browsing_context_id: TopLevelBrowsingContextId) {
         // Send a flat projection of the history.
         // The final vector is a concatenation of the LoadData of the past entries,
         // the current entry and the future entries.
         // LoadData of inner frames are ignored and replaced with the LoadData of the parent.
@@ -2574,30 +2514,25 @@ impl<Message, LTF, STF> Constellation<Me
             // Deactivate the old pipeline, and activate the new one.
             self.update_activity(old_pipeline_id);
             self.update_activity(change.new_pipeline_id);
             // Clear the joint session future
             self.clear_joint_session_future(change.top_level_browsing_context_id);
             self.notify_history_changed(change.top_level_browsing_context_id);
         }
 
-        // If the navigation is for a top-level browsing context, inform mozbrowser
-        if change.browsing_context_id == change.top_level_browsing_context_id {
-            self.trigger_mozbrowserlocationchange(change.top_level_browsing_context_id);
-        }
-
         self.update_frame_tree_if_active(change.top_level_browsing_context_id);
     }
 
     fn handle_activate_document_msg(&mut self, pipeline_id: PipelineId) {
         debug!("Document ready to activate {}", pipeline_id);
 
         // Notify the parent (if there is one).
         if let Some(pipeline) = self.pipelines.get(&pipeline_id) {
-            if let Some((parent_pipeline_id, _)) = pipeline.parent_info {
+            if let Some(parent_pipeline_id) = pipeline.parent_info {
                 if let Some(parent_pipeline) = self.pipelines.get(&parent_pipeline_id) {
                     let msg = ConstellationControlMsg::UpdatePipelineId(parent_pipeline_id,
                         pipeline.browsing_context_id, pipeline_id, UpdatePipelineIdReason::Navigation);
                     let _ = parent_pipeline.event_loop.send(msg);
                 }
             }
         }
 
@@ -2754,17 +2689,17 @@ impl<Message, LTF, STF> Constellation<Me
 
     /// Get the current activity of a pipeline.
     fn get_activity(&self, pipeline_id: PipelineId) -> DocumentActivity {
         let mut ancestor_id = pipeline_id;
         loop {
             if let Some(ancestor) = self.pipelines.get(&ancestor_id) {
                 if let Some(browsing_context) = self.browsing_contexts.get(&ancestor.browsing_context_id) {
                     if browsing_context.pipeline_id == ancestor_id {
-                        if let Some((parent_id, FrameType::IFrame)) = ancestor.parent_info {
+                        if let Some(parent_id) = ancestor.parent_info {
                             ancestor_id = parent_id;
                             continue;
                         } else {
                             return DocumentActivity::FullyActive;
                         }
                     }
                 }
             }
@@ -2882,17 +2817,17 @@ impl<Message, LTF, STF> Constellation<Me
 
         if BrowsingContextId::from(browsing_context.top_level_id) == browsing_context_id {
             self.event_loops.remove(&browsing_context.top_level_id);
         }
 
         let parent_info = self.pipelines.get(&browsing_context.pipeline_id)
             .and_then(|pipeline| pipeline.parent_info);
 
-        if let Some((parent_pipeline_id, _)) = parent_info {
+        if let Some(parent_pipeline_id) = parent_info {
             match self.pipelines.get_mut(&parent_pipeline_id) {
                 None => return warn!("Pipeline {:?} child closed after parent.", parent_pipeline_id),
                 Some(parent_pipeline) => parent_pipeline.remove_child(browsing_context_id),
             };
         }
         debug!("Closed browsing context {:?}.", browsing_context_id);
     }
 
@@ -2977,23 +2912,18 @@ impl<Message, LTF, STF> Constellation<Me
             _ => return,
         };
         // In order to get repeatability, we sort the pipeline ids.
         let mut pipeline_ids: Vec<&PipelineId> = self.pipelines.keys().collect();
         pipeline_ids.sort();
         if let Some((ref mut rng, probability)) = self.random_pipeline_closure {
             if let Some(pipeline_id) = rng.choose(&*pipeline_ids) {
                 if let Some(pipeline) = self.pipelines.get(pipeline_id) {
-                    // Don't kill the mozbrowser pipeline
-                    if PREFS.is_mozbrowser_enabled() && pipeline.parent_info.is_none() {
-                        info!("Not closing mozbrowser pipeline {}.", pipeline_id);
-                    } else if
-                        self.pending_changes.iter().any(|change| change.new_pipeline_id == pipeline.id) &&
-                        probability <= rng.gen::<f32>()
-                    {
+                    if self.pending_changes.iter().any(|change| change.new_pipeline_id == pipeline.id) &&
+                        probability <= rng.gen::<f32>() {
                         // We tend not to close pending pipelines, as that almost always
                         // results in pipelines being closed early in their lifecycle,
                         // and not stressing the constellation as much.
                         // https://github.com/servo/servo/issues/18852
                         info!("Not closing pending pipeline {}.", pipeline_id);
                     } else {
                         // Note that we deliberately do not do any of the tidying up
                         // associated with closing a pipeline. The constellation should cope!
@@ -3022,36 +2952,17 @@ impl<Message, LTF, STF> Constellation<Me
                 }
 
                 frame_tree
             })
         })
     }
 
     /// Re-send the frame tree to the compositor.
-    fn update_frame_tree_if_active(&mut self, mut top_level_browsing_context_id: TopLevelBrowsingContextId) {
-        // This might be a mozbrowser iframe, so we need to climb the parent hierarchy,
-        // even though it's a top-level browsing context.
-        // FIXME(paul): to remove once mozbrowser API is removed.
-        let browsing_context_id = BrowsingContextId::from(top_level_browsing_context_id);
-        let mut pipeline_id = match self.browsing_contexts.get(&browsing_context_id) {
-            Some(browsing_context) => browsing_context.pipeline_id,
-            None => return warn!("Sending frame tree for discarded browsing context {}.", browsing_context_id),
-        };
-
-        while let Some(pipeline) = self.pipelines.get(&pipeline_id) {
-            match pipeline.parent_info {
-                Some((parent_id, _)) => pipeline_id = parent_id,
-                None => {
-                    top_level_browsing_context_id = pipeline.top_level_browsing_context_id;
-                    break;
-                },
-            }
-        }
-
+    fn update_frame_tree_if_active(&mut self, top_level_browsing_context_id: TopLevelBrowsingContextId) {
         // Only send the frame tree if it's the active one or if no frame tree
         // has been sent yet.
         if self.active_browser_id.is_none() || Some(top_level_browsing_context_id) == self.active_browser_id {
             self.send_frame_tree(top_level_browsing_context_id);
         }
 
     }
 
@@ -3064,86 +2975,15 @@ impl<Message, LTF, STF> Constellation<Me
         // avoiding this panic would require a mechanism for dealing
         // with low-resource scenarios.
         debug!("Sending frame tree for browsing context {}.", browsing_context_id);
         if let Some(frame_tree) = self.browsing_context_to_sendable(browsing_context_id) {
             self.compositor_proxy.send(ToCompositorMsg::SetFrameTree(frame_tree));
         }
     }
 
-    // https://developer.mozilla.org/en-US/docs/Web/Events/mozbrowserlocationchange
-    // Note that this is a no-op if the pipeline is not a mozbrowser iframe
-    fn trigger_mozbrowserlocationchange(&self,
-                                        top_level_browsing_context_id: TopLevelBrowsingContextId)
-    {
-        let browsing_context_id = BrowsingContextId::from(top_level_browsing_context_id);
-        let pipeline_id = match self.browsing_contexts.get(&browsing_context_id) {
-            Some(browsing_context) => browsing_context.pipeline_id,
-            None => return warn!("mozbrowser location change on closed browsing context {}.", browsing_context_id),
-        };
-        let (url, parent_info) = match self.pipelines.get(&pipeline_id) {
-            Some(pipeline) => (pipeline.url.clone(), pipeline.parent_info),
-            None => return warn!("mozbrowser location change on closed pipeline {}.", pipeline_id),
-        };
-        let parent_id = match parent_info {
-            Some((parent_id, FrameType::MozBrowserIFrame)) => parent_id,
-            _ => return debug!("mozbrowser location change on a regular iframe {}", browsing_context_id),
-        };
-        let can_go_forward = !self.joint_session_future_is_empty(top_level_browsing_context_id);
-        let can_go_back = !self.joint_session_past_is_empty(top_level_browsing_context_id);
-        let event = MozBrowserEvent::LocationChange(url.to_string(), can_go_back, can_go_forward);
-        match self.pipelines.get(&parent_id) {
-            Some(parent) => parent.trigger_mozbrowser_event(Some(top_level_browsing_context_id), event),
-            None => return warn!("mozbrowser location change on closed parent {}", parent_id),
-        };
-    }
-
-    // https://developer.mozilla.org/en-US/docs/Web/Events/mozbrowsererror
-    fn trigger_mozbrowsererror(&mut self,
-                               top_level_browsing_context_id: TopLevelBrowsingContextId,
-                               reason: String,
-                               backtrace: Option<String>)
-    {
-        if !PREFS.is_mozbrowser_enabled() { return; }
-
-        let mut report = String::new();
-        for (thread_name, warning) in self.handled_warnings.drain(..) {
-            report.push_str("\nWARNING: ");
-            if let Some(thread_name) = thread_name {
-                report.push_str("<");
-                report.push_str(&*thread_name);
-                report.push_str(">: ");
-            }
-            report.push_str(&*warning);
-        }
-        report.push_str("\nERROR: ");
-        report.push_str(&*reason);
-        if let Some(backtrace) = backtrace {
-            report.push_str("\n\n");
-            report.push_str(&*backtrace);
-        }
-
-        let event = MozBrowserEvent::Error(MozBrowserErrorType::Fatal, reason, report);
-        let browsing_context_id = BrowsingContextId::from(top_level_browsing_context_id);
-        let pipeline_id = match self.browsing_contexts.get(&browsing_context_id) {
-            Some(browsing_context) => browsing_context.pipeline_id,
-            None => return warn!("Mozbrowser error after top-level browsing context closed."),
-        };
-        let parent_id = match self.pipelines.get(&pipeline_id) {
-            Some(pipeline) => match pipeline.parent_info {
-                Some((parent_id, FrameType::MozBrowserIFrame)) => parent_id,
-                _ => return pipeline.trigger_mozbrowser_event(None, event),
-            },
-            None => return warn!("Mozbrowser error on a closed pipeline {}", pipeline_id),
-        };
-        match self.pipelines.get(&parent_id) {
-            None => warn!("Mozbrowser error after parent pipeline {} closed.", parent_id),
-            Some(parent) => parent.trigger_mozbrowser_event(Some(top_level_browsing_context_id), event),
-        };
-    }
-
     fn focused_pipeline_is_descendant_of(&self, browsing_context_id: BrowsingContextId) -> bool {
         self.focus_pipeline_id.map_or(false, |pipeline_id| {
             self.fully_active_descendant_browsing_contexts_iter(browsing_context_id)
                 .any(|browsing_context| browsing_context.pipeline_id == pipeline_id)
         })
     }
 }
--- a/servo/components/constellation/pipeline.rs
+++ b/servo/components/constellation/pipeline.rs
@@ -11,25 +11,25 @@ use devtools_traits::{DevtoolsControlMsg
 use euclid::{TypedSize2D, TypedScale};
 use event_loop::EventLoop;
 use gfx::font_cache_thread::FontCacheThread;
 use ipc_channel::Error;
 use ipc_channel::ipc::{self, IpcReceiver, IpcSender};
 use ipc_channel::router::ROUTER;
 use layout_traits::LayoutThreadFactory;
 use metrics::PaintTimeMetrics;
-use msg::constellation_msg::{BrowsingContextId, TopLevelBrowsingContextId, FrameType, PipelineId, PipelineNamespaceId};
+use msg::constellation_msg::{BrowsingContextId, TopLevelBrowsingContextId, PipelineId, PipelineNamespaceId};
 use net::image_cache::ImageCacheImpl;
 use net_traits::{IpcSend, ResourceThreads};
 use net_traits::image_cache::ImageCache;
 use profile_traits::mem as profile_mem;
 use profile_traits::time;
 use script_traits::{ConstellationControlMsg, DiscardBrowsingContext, ScriptToConstellationChan};
 use script_traits::{DocumentActivity, InitialScriptState};
-use script_traits::{LayoutControlMsg, LayoutMsg, LoadData, MozBrowserEvent};
+use script_traits::{LayoutControlMsg, LayoutMsg, LoadData};
 use script_traits::{NewLayoutInfo, SWManagerMsg, SWManagerSenders};
 use script_traits::{ScriptThreadFactory, TimerSchedulerMsg, WindowSizeData};
 use servo_config::opts::{self, Opts};
 use servo_config::prefs::{PREFS, Pref};
 use servo_url::ServoUrl;
 use std::collections::HashMap;
 #[cfg(not(windows))]
 use std::env;
@@ -53,21 +53,18 @@ pub struct Pipeline {
 
     /// The ID of the browsing context that contains this Pipeline.
     pub browsing_context_id: BrowsingContextId,
 
     /// The ID of the top-level browsing context that contains this Pipeline.
     pub top_level_browsing_context_id: TopLevelBrowsingContextId,
 
     /// The parent pipeline of this one. `None` if this is a root pipeline.
-    /// Note that because of mozbrowser iframes, even top-level pipelines
-    /// may have a parent (in which case the frame type will be
-    /// `MozbrowserIFrame`).
     /// TODO: move this field to `BrowsingContext`.
-    pub parent_info: Option<(PipelineId, FrameType)>,
+    pub parent_info: Option<PipelineId>,
 
     /// The event loop handling this pipeline.
     pub event_loop: Rc<EventLoop>,
 
     /// A channel to layout, for performing reflows and shutdown.
     pub layout_chan: IpcSender<LayoutControlMsg>,
 
     /// A channel to the compositor.
@@ -105,17 +102,17 @@ pub struct InitialPipelineState {
     /// The ID of the browsing context that contains this Pipeline.
     pub browsing_context_id: BrowsingContextId,
 
     /// The ID of the top-level browsing context that contains this Pipeline.
     pub top_level_browsing_context_id: TopLevelBrowsingContextId,
 
     /// The ID of the parent pipeline and frame type, if any.
     /// If `None`, this is the root.
-    pub parent_info: Option<(PipelineId, FrameType)>,
+    pub parent_info: Option<PipelineId>,
 
     /// A channel to the associated constellation.
     pub script_to_constellation_chan: ScriptToConstellationChan,
 
     /// A channel for the layout thread to send messages to the constellation.
     pub layout_to_constellation_chan: IpcSender<LayoutMsg>,
 
     /// A channel to schedule timer events.
@@ -304,17 +301,17 @@ impl Pipeline {
                          state.prev_visibility.unwrap_or(true)))
     }
 
     /// Creates a new `Pipeline`, after the script and layout threads have been
     /// spawned.
     pub fn new(id: PipelineId,
                browsing_context_id: BrowsingContextId,
                top_level_browsing_context_id: TopLevelBrowsingContextId,
-               parent_info: Option<(PipelineId, FrameType)>,
+               parent_info: Option<PipelineId>,
                event_loop: Rc<EventLoop>,
                layout_chan: IpcSender<LayoutControlMsg>,
                compositor_proxy: CompositorProxy,
                is_private: bool,
                url: ServoUrl,
                visible: bool)
                -> Pipeline {
         let pipeline = Pipeline {
@@ -400,32 +397,16 @@ impl Pipeline {
     /// Remove a child browsing context.
     pub fn remove_child(&mut self, browsing_context_id: BrowsingContextId) {
         match self.children.iter().position(|id| *id == browsing_context_id) {
             None => return warn!("Pipeline remove child already removed ({:?}).", browsing_context_id),
             Some(index) => self.children.remove(index),
         };
     }
 
-    /// Send a mozbrowser event to the script thread for this pipeline.
-    /// This will cause an event to be fired on an iframe in the document,
-    /// or on the `Window` if no frame is given.
-    pub fn trigger_mozbrowser_event(&self,
-                                     child_id: Option<TopLevelBrowsingContextId>,
-                                     event: MozBrowserEvent) {
-        assert!(PREFS.is_mozbrowser_enabled());
-
-        let event = ConstellationControlMsg::MozBrowserEvent(self.id,
-                                                             child_id,
-                                                             event);
-        if let Err(e) = self.event_loop.send(event) {
-            warn!("Sending mozbrowser event to script failed ({}).", e);
-        }
-    }
-
     /// Notify the script thread that this pipeline is visible.
     fn notify_visibility(&self) {
         let script_msg = ConstellationControlMsg::ChangeFrameVisibilityStatus(self.id, self.visible);
         let compositor_msg = CompositorMsg::PipelineVisibilityChanged(self.id, self.visible);
         let err = self.event_loop.send(script_msg);
         if let Err(e) = err {
             warn!("Sending visibility change failed ({}).", e);
         }
@@ -446,17 +427,17 @@ impl Pipeline {
 /// Creating a new pipeline may require creating a new event loop.
 /// This is the data used to initialize the event loop.
 /// TODO: simplify this, and unify it with `InitialPipelineState` if possible.
 #[derive(Deserialize, Serialize)]
 pub struct UnprivilegedPipelineContent {
     id: PipelineId,
     top_level_browsing_context_id: TopLevelBrowsingContextId,
     browsing_context_id: BrowsingContextId,
-    parent_info: Option<(PipelineId, FrameType)>,
+    parent_info: Option<PipelineId>,
     script_to_constellation_chan: ScriptToConstellationChan,
     layout_to_constellation_chan: IpcSender<LayoutMsg>,
     scheduler_chan: IpcSender<TimerSchedulerMsg>,
     devtools_chan: Option<IpcSender<ScriptToDevtoolsControlMsg>>,
     bluetooth_thread: IpcSender<BluetoothRequest>,
     swmanager_thread: IpcSender<SWManagerMsg>,
     font_cache_thread: FontCacheThread,
     resource_threads: ResourceThreads,
--- a/servo/components/msg/constellation_msg.rs
+++ b/servo/components/msg/constellation_msg.rs
@@ -360,15 +360,8 @@ pub const TEST_PIPELINE_INDEX: PipelineI
 pub const TEST_PIPELINE_ID: PipelineId = PipelineId { namespace_id: TEST_NAMESPACE, index: TEST_PIPELINE_INDEX };
 #[allow(unsafe_code)]
 #[cfg(feature = "unstable")]
 pub const TEST_BROWSING_CONTEXT_INDEX: BrowsingContextIndex =
     unsafe { BrowsingContextIndex(NonZero::new_unchecked(8765)) };
 #[cfg(feature = "unstable")]
 pub const TEST_BROWSING_CONTEXT_ID: BrowsingContextId =
     BrowsingContextId { namespace_id: TEST_NAMESPACE, index: TEST_BROWSING_CONTEXT_INDEX };
-
-#[derive(Clone, Copy, Debug, Deserialize, Eq, Hash, MallocSizeOf, PartialEq, Serialize)]
-pub enum FrameType {
-    IFrame,
-    MozBrowserIFrame,
-}
-
--- a/servo/components/script/Cargo.toml
+++ b/servo/components/script/Cargo.toml
@@ -62,17 +62,16 @@ metrics = {path = "../metrics"}
 mitochondria = "1.1.2"
 mime = "0.2.1"
 mime_guess = "1.8.0"
 mozjs = { version = "0.1.10", features = ["promises"]}
 msg = {path = "../msg"}
 net_traits = {path = "../net_traits"}
 num-traits = "0.1.32"
 offscreen_gl_context = { version = "0.14", features = ["serde"] }
-open = "1.1.1"
 parking_lot = "0.4"
 phf = "0.7.18"
 profile_traits = {path = "../profile_traits"}
 ref_filter_map = "1.0.1"
 ref_slice = "1.0"
 regex = "0.2"
 script_layout_interface = {path = "../script_layout_interface"}
 script_plugins = {path = "../script_plugins"}
--- a/servo/components/script/dom/bindings/trace.rs
+++ b/servo/components/script/dom/bindings/trace.rs
@@ -58,33 +58,33 @@ use hyper::method::Method;
 use hyper::mime::Mime;
 use hyper::status::StatusCode;
 use ipc_channel::ipc::{IpcReceiver, IpcSender};
 use js::glue::{CallObjectTracer, CallValueTracer};
 use js::jsapi::{GCTraceKindToAscii, Heap, JSObject, JSTracer, TraceKind};
 use js::jsval::JSVal;
 use js::rust::Runtime;
 use metrics::{InteractiveMetrics, InteractiveWindow};
-use msg::constellation_msg::{BrowsingContextId, FrameType, PipelineId, TopLevelBrowsingContextId};
+use msg::constellation_msg::{BrowsingContextId, PipelineId, TopLevelBrowsingContextId};
 use net_traits::{Metadata, NetworkError, ReferrerPolicy, ResourceThreads};
 use net_traits::filemanager_thread::RelativePos;
 use net_traits::image::base::{Image, ImageMetadata};
 use net_traits::image_cache::{ImageCache, PendingImageId};
 use net_traits::request::{Request, RequestInit};
 use net_traits::response::{Response, ResponseBody};
 use net_traits::response::HttpsState;
 use net_traits::storage_thread::StorageType;
 use offscreen_gl_context::GLLimits;
 use parking_lot::RwLock;
 use profile_traits::mem::ProfilerChan as MemProfilerChan;
 use profile_traits::time::ProfilerChan as TimeProfilerChan;
 use script_layout_interface::OpaqueStyleAndLayoutData;
 use script_layout_interface::reporter::CSSErrorReporter;
 use script_layout_interface::rpc::LayoutRPC;
-use script_traits::{DocumentActivity, ScriptToConstellationChan, TimerEventId, TimerSource, TouchpadPressurePhase};
+use script_traits::{DocumentActivity, ScriptToConstellationChan, TimerEventId, TimerSource};
 use script_traits::{UntrustedNodeAddress, WindowSizeData, WindowSizeType};
 use script_traits::DrawAPaintImageResult;
 use selectors::matching::ElementSelectorFlags;
 use serde::{Deserialize, Serialize};
 use servo_arc::Arc as ServoArc;
 use servo_atoms::Atom;
 use servo_url::{ImmutableOrigin, MutableOrigin, ServoUrl};
 use smallvec::SmallVec;
@@ -346,17 +346,17 @@ unsafe_no_jsmanaged_fields!(Image, Image
 unsafe_no_jsmanaged_fields!(Metadata);
 unsafe_no_jsmanaged_fields!(NetworkError);
 unsafe_no_jsmanaged_fields!(Atom, Prefix, LocalName, Namespace, QualName);
 unsafe_no_jsmanaged_fields!(TrustedPromise);
 unsafe_no_jsmanaged_fields!(PropertyDeclarationBlock);
 // These three are interdependent, if you plan to put jsmanaged data
 // in one of these make sure it is propagated properly to containing structs
 unsafe_no_jsmanaged_fields!(DocumentActivity, WindowSizeData, WindowSizeType);
-unsafe_no_jsmanaged_fields!(BrowsingContextId, FrameType, PipelineId, TopLevelBrowsingContextId);
+unsafe_no_jsmanaged_fields!(BrowsingContextId, PipelineId, TopLevelBrowsingContextId);
 unsafe_no_jsmanaged_fields!(TimerEventId, TimerSource);
 unsafe_no_jsmanaged_fields!(TimelineMarkerType);
 unsafe_no_jsmanaged_fields!(WorkerId);
 unsafe_no_jsmanaged_fields!(BufferQueue, QuirksMode, IncompleteUtf8);
 unsafe_no_jsmanaged_fields!(Runtime);
 unsafe_no_jsmanaged_fields!(Headers, Method);
 unsafe_no_jsmanaged_fields!(WindowProxyHandler);
 unsafe_no_jsmanaged_fields!(UntrustedNodeAddress);
@@ -380,17 +380,16 @@ unsafe_no_jsmanaged_fields!(AttrValue);
 unsafe_no_jsmanaged_fields!(Snapshot);
 unsafe_no_jsmanaged_fields!(PendingRestyle);
 unsafe_no_jsmanaged_fields!(Stylesheet);
 unsafe_no_jsmanaged_fields!(HttpsState);
 unsafe_no_jsmanaged_fields!(Request);
 unsafe_no_jsmanaged_fields!(RequestInit);
 unsafe_no_jsmanaged_fields!(SharedRt);
 unsafe_no_jsmanaged_fields!(StyleSharedRwLock);
-unsafe_no_jsmanaged_fields!(TouchpadPressurePhase);
 unsafe_no_jsmanaged_fields!(USVString);
 unsafe_no_jsmanaged_fields!(ReferrerPolicy);
 unsafe_no_jsmanaged_fields!(Response);
 unsafe_no_jsmanaged_fields!(ResponseBody);
 unsafe_no_jsmanaged_fields!(ResourceThreads);
 unsafe_no_jsmanaged_fields!(StatusCode);
 unsafe_no_jsmanaged_fields!(SystemTime);
 unsafe_no_jsmanaged_fields!(Instant);
--- a/servo/components/script/dom/document.rs
+++ b/servo/components/script/dom/document.rs
@@ -37,17 +37,16 @@ use dom::documentfragment::DocumentFragm
 use dom::documenttype::DocumentType;
 use dom::domimplementation::DOMImplementation;
 use dom::element::{Element, ElementCreator, ElementPerformFullscreenEnter, ElementPerformFullscreenExit};
 use dom::element::CustomElementCreationMode;
 use dom::errorevent::ErrorEvent;
 use dom::event::{Event, EventBubbles, EventCancelable, EventDefault, EventStatus};
 use dom::eventtarget::EventTarget;
 use dom::focusevent::FocusEvent;
-use dom::forcetouchevent::ForceTouchEvent;
 use dom::globalscope::GlobalScope;
 use dom::hashchangeevent::HashChangeEvent;
 use dom::htmlanchorelement::HTMLAnchorElement;
 use dom::htmlareaelement::HTMLAreaElement;
 use dom::htmlbaseelement::HTMLBaseElement;
 use dom::htmlbodyelement::HTMLBodyElement;
 use dom::htmlcollection::{CollectionFilter, HTMLCollection};
 use dom::htmlelement::HTMLElement;
@@ -94,31 +93,30 @@ use fetch::FetchCanceller;
 use html5ever::{LocalName, Namespace, QualName};
 use hyper::header::{Header, SetCookie};
 use hyper_serde::Serde;
 use ipc_channel::ipc::{self, IpcSender};
 use js::jsapi::{JSContext, JSObject, JSRuntime};
 use js::jsapi::JS_GetRuntime;
 use metrics::{InteractiveFlag, InteractiveMetrics, InteractiveWindow, ProfilerMetadataFactory, ProgressiveWebMetric};
 use mime::{Mime, TopLevel, SubLevel};
-use msg::constellation_msg::{BrowsingContextId, Key, KeyModifiers, KeyState, TopLevelBrowsingContextId};
+use msg::constellation_msg::{BrowsingContextId, Key, KeyModifiers, KeyState};
 use net_traits::{FetchResponseMsg, IpcSend, ReferrerPolicy};
 use net_traits::CookieSource::NonHTTP;
 use net_traits::CoreResourceMsg::{GetCookiesForUrl, SetCookiesForUrl};
 use net_traits::pub_domains::is_pub_domain;
 use net_traits::request::RequestInit;
 use net_traits::response::HttpsState;
 use num_traits::ToPrimitive;
 use profile_traits::time::{TimerMetadata, TimerMetadataFrameType, TimerMetadataReflowType};
 use script_layout_interface::message::{Msg, NodesFromPointQueryType, ReflowGoal};
 use script_runtime::{CommonScriptMsg, ScriptThreadEventCategory};
 use script_thread::{MainThreadScriptMsg, ScriptThread};
 use script_traits::{AnimationState, DocumentActivity, MouseButton, MouseEventType};
-use script_traits::{MozBrowserEvent, MsDuration, ScriptMsg, TouchEventType, TouchId};
-use script_traits::{TouchpadPressurePhase, UntrustedNodeAddress};
+use script_traits::{MsDuration, ScriptMsg, TouchEventType, TouchId, UntrustedNodeAddress};
 use servo_arc::Arc;
 use servo_atoms::Atom;
 use servo_config::prefs::PREFS;
 use servo_url::{ImmutableOrigin, MutableOrigin, ServoUrl};
 use std::borrow::ToOwned;
 use std::cell::{Cell, Ref, RefMut};
 use std::collections::{HashMap, HashSet, VecDeque};
 use std::collections::hash_map::Entry::{Occupied, Vacant};
@@ -323,17 +321,16 @@ pub struct Document {
     dom_content_loaded_event_start: Cell<u64>,
     dom_content_loaded_event_end: Cell<u64>,
     dom_complete: Cell<u64>,
     top_level_dom_complete: Cell<u64>,
     load_event_start: Cell<u64>,
     load_event_end: Cell<u64>,
     /// <https://html.spec.whatwg.org/multipage/#concept-document-https-state>
     https_state: Cell<HttpsState>,
-    touchpad_pressure_phase: Cell<TouchpadPressurePhase>,
     /// The document's origin.
     origin: MutableOrigin,
     ///  https://w3c.github.io/webappsec-referrer-policy/#referrer-policy-states
     referrer_policy: Cell<Option<ReferrerPolicy>>,
     /// <https://html.spec.whatwg.org/multipage/#dom-document-referrer>
     referrer: Option<String>,
     /// <https://html.spec.whatwg.org/multipage/#target-element>
     target_element: MutNullableDom<Element>,
@@ -449,17 +446,16 @@ impl Document {
 
     #[inline]
     pub fn is_html_document(&self) -> bool {
         self.is_html_document
     }
 
     pub fn set_https_state(&self, https_state: HttpsState) {
         self.https_state.set(https_state);
-        self.trigger_mozbrowser_event(MozBrowserEvent::SecurityChange(https_state));
     }
 
     pub fn is_fully_active(&self) -> bool {
         self.activity.get() == DocumentActivity::FullyActive
     }
 
     pub fn is_active(&self) -> bool {
         self.activity.get() != DocumentActivity::Inactive
@@ -752,23 +748,19 @@ impl Document {
                 .find(|node| check_anchor(&node))
                 .map(DomRoot::upcast)
     }
 
     // https://html.spec.whatwg.org/multipage/#current-document-readiness
     pub fn set_ready_state(&self, state: DocumentReadyState) {
         match state {
             DocumentReadyState::Loading => {
-                // https://developer.mozilla.org/en-US/docs/Web/Events/mozbrowserconnected
-                self.trigger_mozbrowser_event(MozBrowserEvent::Connected);
                 update_with_current_time_ms(&self.dom_loading);
             },
             DocumentReadyState::Complete => {
-                // https://developer.mozilla.org/en-US/docs/Web/Events/mozbrowserloadend
-                self.trigger_mozbrowser_event(MozBrowserEvent::LoadEnd);
                 update_with_current_time_ms(&self.dom_complete);
             },
             DocumentReadyState::Interactive => update_with_current_time_ms(&self.dom_interactive),
         };
 
         self.ready_state.set(state);
 
         self.upcast::<EventTarget>().fire_event(atom!("readystatechange"));
@@ -824,19 +816,16 @@ impl Document {
                 self.send_to_constellation(ScriptMsg::Focus);
             }
         }
     }
 
     /// Handles any updates when the document's title has changed.
     pub fn title_changed(&self) {
         if self.browsing_context().is_some() {
-            // https://developer.mozilla.org/en-US/docs/Web/Events/mozbrowsertitlechange
-            self.trigger_mozbrowser_event(MozBrowserEvent::TitleChange(String::from(self.Title())));
-
             self.send_title_to_constellation();
         }
     }
 
     /// Sends this document's title to the constellation.
     pub fn send_title_to_constellation(&self) {
         let title = Some(String::from(self.Title()));
         self.send_to_constellation(ScriptMsg::SetTitle(title));
@@ -993,75 +982,16 @@ impl Document {
                 return;
             }
         }
 
         // Update last_click_info with the time and position of the click.
         *self.last_click_info.borrow_mut() = Some((now, click_pos));
     }
 
-    #[allow(unsafe_code)]
-    pub fn handle_touchpad_pressure_event(
-        &self,
-        js_runtime: *mut JSRuntime,
-        pressure: f32,
-        phase_now: TouchpadPressurePhase,
-        node_address: Option<UntrustedNodeAddress>
-    ) {
-        let el = node_address.and_then(|address| {
-            let node = unsafe { node::from_untrusted_node_address(js_runtime, address) };
-            node.inclusive_ancestors()
-                .filter_map(DomRoot::downcast::<Element>)
-                .next()
-        });
-        let el = match el {
-            Some(el) => el,
-            None => return,
-        };
-
-        let phase_before = self.touchpad_pressure_phase.get();
-        self.touchpad_pressure_phase.set(phase_now);
-
-        if phase_before == TouchpadPressurePhase::BeforeClick &&
-           phase_now == TouchpadPressurePhase::BeforeClick {
-            return;
-        }
-
-        let node = el.upcast::<Node>();
-        let target = node.upcast();
-
-        let force = match phase_now {
-            TouchpadPressurePhase::BeforeClick => pressure,
-            TouchpadPressurePhase::AfterFirstClick => 1. + pressure,
-            TouchpadPressurePhase::AfterSecondClick => 2. + pressure,
-        };
-
-        if phase_now != TouchpadPressurePhase::BeforeClick {
-            self.fire_forcetouch_event("servomouseforcechanged".to_owned(), target, force);
-        }
-
-        if phase_before != TouchpadPressurePhase::AfterSecondClick &&
-           phase_now == TouchpadPressurePhase::AfterSecondClick {
-            self.fire_forcetouch_event("servomouseforcedown".to_owned(), target, force);
-        }
-
-        if phase_before == TouchpadPressurePhase::AfterSecondClick &&
-           phase_now != TouchpadPressurePhase::AfterSecondClick {
-            self.fire_forcetouch_event("servomouseforceup".to_owned(), target, force);
-        }
-    }
-
-    fn fire_forcetouch_event(&self, event_name: String, target: &EventTarget, force: f32) {
-        let force_event = ForceTouchEvent::new(&self.window,
-                                               DOMString::from(event_name),
-                                               force);
-        let event = force_event.upcast::<Event>();
-        event.fire(target);
-    }
-
     pub fn fire_mouse_event(&self, client_point: Point2D<f32>, target: &EventTarget, event_name: FireMouseEventType) {
         let client_x = client_point.x.to_i32().unwrap_or(0);
         let client_y = client_point.y.to_i32().unwrap_or(0);
 
         let mouse_event = MouseEvent::new(
             &self.window,
             DOMString::from(event_name.as_str()),
             EventBubbles::Bubbles,
@@ -1467,25 +1397,16 @@ impl Document {
         // Mark the document element dirty so a reflow will be performed.
         //
         // FIXME(emilio): Use the DocumentStylesheetSet invalidation stuff.
         if let Some(element) = self.GetDocumentElement() {
             element.upcast::<Node>().dirty(NodeDamage::NodeStyleDamaged);
         }
     }
 
-    pub fn trigger_mozbrowser_event(&self, event: MozBrowserEvent) {
-        if PREFS.is_mozbrowser_enabled() {
-            if let Some((parent_pipeline_id, _)) = self.window.parent_info() {
-                let event = ScriptMsg::MozBrowserEvent(parent_pipeline_id, event);
-                self.send_to_constellation(event);
-            }
-        }
-    }
-
     /// <https://html.spec.whatwg.org/multipage/#dom-window-requestanimationframe>
     pub fn request_animation_frame(&self, callback: AnimationFrameCallback) -> u32 {
         let ident = self.animation_frame_ident.get() + 1;
 
         self.animation_frame_ident.set(ident);
         self.animation_frame_list.borrow_mut().push((ident, Some(callback)));
 
         // TODO: Should tick animation only when document is visible
@@ -1914,30 +1835,16 @@ impl Document {
     }
 
     /// Find an iframe element in the document.
     pub fn find_iframe(&self, browsing_context_id: BrowsingContextId) -> Option<DomRoot<HTMLIFrameElement>> {
         self.iter_iframes()
             .find(|node| node.browsing_context_id() == Some(browsing_context_id))
     }
 
-    /// Find a mozbrowser iframe element in the document.
-    pub fn find_mozbrowser_iframe(&self,
-                                  top_level_browsing_context_id: TopLevelBrowsingContextId)
-                                  -> Option<DomRoot<HTMLIFrameElement>>
-    {
-        match self.find_iframe(BrowsingContextId::from(top_level_browsing_context_id)) {
-            None => None,
-            Some(iframe) => {
-                assert!(iframe.Mozbrowser());
-                Some(iframe)
-            },
-        }
-    }
-
     pub fn get_dom_loading(&self) -> u64 {
         self.dom_loading.get()
     }
 
     pub fn get_dom_interactive(&self) -> u64 {
         self.dom_interactive.get()
     }
 
@@ -2292,17 +2199,16 @@ impl Document {
             dom_interactive: Cell::new(Default::default()),
             dom_content_loaded_event_start: Cell::new(Default::default()),
             dom_content_loaded_event_end: Cell::new(Default::default()),
             dom_complete: Cell::new(Default::default()),
             top_level_dom_complete: Cell::new(Default::default()),
             load_event_start: Cell::new(Default::default()),
             load_event_end: Cell::new(Default::default()),
             https_state: Cell::new(HttpsState::None),
-            touchpad_pressure_phase: Cell::new(TouchpadPressurePhase::BeforeClick),
             origin: origin,
             referrer: referrer,
             referrer_policy: Cell::new(referrer_policy),
             target_element: MutNullableDom::new(None),
             last_click_info: DomRefCell::new(None),
             ignore_destructive_writes_counter: Default::default(),
             spurious_animation_frames: Cell::new(0),
             dom_count: Cell::new(1),
deleted file mode 100644
--- a/servo/components/script/dom/forcetouchevent.rs
+++ /dev/null
@@ -1,58 +0,0 @@
-/* This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-
-use dom::bindings::codegen::Bindings::ForceTouchEventBinding;
-use dom::bindings::codegen::Bindings::ForceTouchEventBinding::ForceTouchEventMethods;
-use dom::bindings::codegen::Bindings::UIEventBinding::UIEventMethods;
-use dom::bindings::inheritance::Castable;
-use dom::bindings::num::Finite;
-use dom::bindings::reflector::reflect_dom_object;
-use dom::bindings::root::DomRoot;
-use dom::bindings::str::DOMString;
-use dom::uievent::UIEvent;
-use dom::window::Window;
-use dom_struct::dom_struct;
-
-#[dom_struct]
-pub struct ForceTouchEvent {
-    uievent: UIEvent,
-    force: f32,
-}
-
-impl ForceTouchEvent {
-    fn new_inherited(force: f32) -> ForceTouchEvent {
-        ForceTouchEvent {
-            uievent: UIEvent::new_inherited(),
-            force: force,
-        }
-    }
-
-    pub fn new(window: &Window,
-               type_: DOMString,
-               force: f32) -> DomRoot<ForceTouchEvent> {
-        let event = Box::new(ForceTouchEvent::new_inherited(force));
-        let ev = reflect_dom_object(event, window, ForceTouchEventBinding::Wrap);
-        ev.upcast::<UIEvent>().InitUIEvent(type_, true, true, Some(window), 0);
-        ev
-    }
-}
-
-impl<'a> ForceTouchEventMethods for &'a ForceTouchEvent {
-    fn ServoForce(&self) -> Finite<f32> {
-        Finite::wrap(self.force)
-    }
-
-    fn SERVO_FORCE_AT_MOUSE_DOWN(&self) -> Finite<f32> {
-        Finite::wrap(1.0)
-    }
-
-    fn SERVO_FORCE_AT_FORCE_MOUSE_DOWN(&self) -> Finite<f32> {
-        Finite::wrap(2.0)
-    }
-
-    // https://dom.spec.whatwg.org/#dom-event-istrusted
-    fn IsTrusted(&self) -> bool {
-        self.uievent.IsTrusted()
-    }
-}
--- a/servo/components/script/dom/htmlanchorelement.rs
+++ b/servo/components/script/dom/htmlanchorelement.rs
@@ -23,18 +23,16 @@ use dom::htmlimageelement::HTMLImageElem
 use dom::mouseevent::MouseEvent;
 use dom::node::{Node, document_from_node};
 use dom::urlhelper::UrlHelper;
 use dom::virtualmethods::VirtualMethods;
 use dom_struct::dom_struct;
 use html5ever::{LocalName, Prefix};
 use net_traits::ReferrerPolicy;
 use num_traits::ToPrimitive;
-use script_traits::MozBrowserEvent;
-use servo_config::prefs::PREFS;
 use servo_url::ServoUrl;
 use std::default::Default;
 use style::attr::AttrValue;
 
 #[dom_struct]
 pub struct HTMLAnchorElement {
     htmlelement: HTMLElement,
     rel_list: MutNullableDom<DOMTokenList>,
@@ -603,23 +601,18 @@ pub fn follow_hyperlink(subject: &Elemen
     let document = document_from_node(subject);
     let url = match document.url().join(&href) {
         Ok(url) => url,
         Err(_) => return,
     };
 
     // Step 8: navigate to the URL.
     if let Some(target) = target {
-        if PREFS.is_mozbrowser_enabled() && !is_current_browsing_context(target.Value()) {
-            // https://developer.mozilla.org/en-US/docs/Web/Events/mozbrowseropenwindow
-            // TODO: referrer and opener
-            // TODO: should we send the normalized url or the non-normalized href?
-            let event = MozBrowserEvent::OpenWindow(url.into_string(), Some(String::from(target.Value())), None);
-            document.trigger_mozbrowser_event(event);
-            return
+        if !is_current_browsing_context(target.Value()) {
+            // https://github.com/servo/servo/issues/13241
         }
     }
 
     debug!("following hyperlink to {}", url);
 
     let window = document.window();
     window.load_url(url, false, false, referrer_policy);
 }
--- a/servo/components/script/dom/htmliframeelement.rs
+++ b/servo/components/script/dom/htmliframeelement.rs
@@ -1,60 +1,43 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 use document_loader::{LoadBlocker, LoadType};
 use dom::attr::Attr;
 use dom::bindings::cell::DomRefCell;
-use dom::bindings::codegen::Bindings::BrowserElementBinding::BrowserElementErrorEventDetail;
-use dom::bindings::codegen::Bindings::BrowserElementBinding::BrowserElementIconChangeEventDetail;
-use dom::bindings::codegen::Bindings::BrowserElementBinding::BrowserElementLocationChangeEventDetail;
-use dom::bindings::codegen::Bindings::BrowserElementBinding::BrowserElementOpenTabEventDetail;
-use dom::bindings::codegen::Bindings::BrowserElementBinding::BrowserElementOpenWindowEventDetail;
-use dom::bindings::codegen::Bindings::BrowserElementBinding::BrowserElementSecurityChangeDetail;
-use dom::bindings::codegen::Bindings::BrowserElementBinding::BrowserElementVisibilityChangeEventDetail;
-use dom::bindings::codegen::Bindings::BrowserElementBinding::BrowserShowModalPromptEventDetail;
 use dom::bindings::codegen::Bindings::HTMLIFrameElementBinding;
 use dom::bindings::codegen::Bindings::HTMLIFrameElementBinding::HTMLIFrameElementMethods;
 use dom::bindings::codegen::Bindings::WindowBinding::WindowBinding::WindowMethods;
-use dom::bindings::conversions::ToJSValConvertible;
-use dom::bindings::error::{Error, ErrorResult, Fallible};
 use dom::bindings::inheritance::Castable;
 use dom::bindings::refcounted::Trusted;
 use dom::bindings::reflector::DomObject;
 use dom::bindings::root::{LayoutDom, DomRoot, MutNullableDom};
 use dom::bindings::str::DOMString;
-use dom::customevent::CustomEvent;
 use dom::document::Document;
 use dom::domtokenlist::DOMTokenList;
 use dom::element::{AttributeMutation, Element, RawLayoutElementHelpers};
-use dom::event::Event;
 use dom::eventtarget::EventTarget;
 use dom::globalscope::GlobalScope;
 use dom::htmlelement::HTMLElement;
 use dom::node::{Node, NodeDamage, UnbindContext, document_from_node, window_from_node};
 use dom::virtualmethods::VirtualMethods;
-use dom::window::{ReflowReason, Window};
+use dom::window::ReflowReason;
 use dom::windowproxy::WindowProxy;
 use dom_struct::dom_struct;
 use html5ever::{LocalName, Prefix};
 use ipc_channel::ipc;
-use js::jsapi::{JSAutoCompartment, JSContext, MutableHandleValue};
-use js::jsval::{NullValue, UndefinedValue};
-use msg::constellation_msg::{FrameType, BrowsingContextId, PipelineId, TopLevelBrowsingContextId, TraversalDirection};
-use net_traits::response::HttpsState;
+use msg::constellation_msg::{BrowsingContextId, PipelineId, TopLevelBrowsingContextId};
 use script_layout_interface::message::ReflowGoal;
 use script_thread::ScriptThread;
 use script_traits::{IFrameLoadInfo, IFrameLoadInfoWithData, JsEvalResult, LoadData, UpdatePipelineIdReason};
-use script_traits::{MozBrowserEvent, NewLayoutInfo, ScriptMsg};
+use script_traits::{NewLayoutInfo, ScriptMsg};
 use script_traits::IFrameSandboxState::{IFrameSandboxed, IFrameUnsandboxed};
-use servo_atoms::Atom;
 use servo_config::prefs::PREFS;
-use servo_config::servo_version;
 use servo_url::ServoUrl;
 use std::cell::Cell;
 use style::attr::{AttrValue, LengthOrPercentageOrAuto};
 use task_source::TaskSource;
 
 bitflags! {
     #[derive(JSTraceable, MallocSizeOf)]
     struct SandboxAllowance: u8 {
@@ -160,41 +143,38 @@ impl HTMLIFrameElement {
                 }
             };
         }
 
         let window = window_from_node(self);
         let old_pipeline_id = self.pipeline_id();
         let new_pipeline_id = PipelineId::new();
         self.pending_pipeline_id.set(Some(new_pipeline_id));
-        let private_iframe = self.privatebrowsing();
-        let frame_type = if self.Mozbrowser() { FrameType::MozBrowserIFrame } else { FrameType::IFrame };
 
         let global_scope = window.upcast::<GlobalScope>();
         let load_info = IFrameLoadInfo {
             parent_pipeline_id: global_scope.pipeline_id(),
             browsing_context_id: browsing_context_id,
             top_level_browsing_context_id: top_level_browsing_context_id,
             new_pipeline_id: new_pipeline_id,
-            is_private: private_iframe,
-            frame_type: frame_type,
+            is_private: false, // FIXME
             replace: replace,
         };
 
         match nav_type {
             NavigationType::InitialAboutBlank => {
                 let (pipeline_sender, pipeline_receiver) = ipc::channel().unwrap();
 
                 global_scope
                     .script_to_constellation_chan()
                     .send(ScriptMsg::ScriptNewIFrame(load_info, pipeline_sender))
                     .unwrap();
 
                 let new_layout_info = NewLayoutInfo {
-                    parent_info: Some((global_scope.pipeline_id(), frame_type)),
+                    parent_info: Some(global_scope.pipeline_id()),
                     new_pipeline_id: new_pipeline_id,
                     browsing_context_id: browsing_context_id,
                     top_level_browsing_context_id: top_level_browsing_context_id,
                     load_data: load_data.unwrap(),
                     pipeline_port: pipeline_receiver,
                     content_process_shutdown_chan: None,
                     window_size: None,
                     layout_threads: PREFS.get("layout.threads").as_u64().expect("count") as usize,
@@ -211,21 +191,16 @@ impl HTMLIFrameElement {
                     sandbox: sandboxed,
                 };
                 global_scope
                   .script_to_constellation_chan()
                   .send(ScriptMsg::ScriptLoadedURLInIFrame(load_info))
                   .unwrap();
             }
         }
-
-        if PREFS.is_mozbrowser_enabled() {
-            // https://developer.mozilla.org/en-US/docs/Web/Events/mozbrowserloadstart
-            self.dispatch_mozbrowser_event(MozBrowserEvent::LoadStart);
-        }
     }
 
     /// <https://html.spec.whatwg.org/multipage/#process-the-iframe-attributes>
     fn process_the_iframe_attributes(&self, mode: ProcessingMode) {
         // TODO: srcdoc
 
         let window = window_from_node(self);
 
@@ -253,40 +228,25 @@ impl HTMLIFrameElement {
             None
         };
 
         let document = document_from_node(self);
         let load_data = LoadData::new(url, creator_pipeline_id, document.get_referrer_policy(), Some(document.url()));
         self.navigate_or_reload_child_browsing_context(Some(load_data), NavigationType::Regular, false);
     }
 
-    #[allow(unsafe_code)]
-    pub fn dispatch_mozbrowser_event(&self, event: MozBrowserEvent) {
-        assert!(PREFS.is_mozbrowser_enabled());
-
-        if self.Mozbrowser() {
-            let window = window_from_node(self);
-            let custom_event = build_mozbrowser_custom_event(&window, event);
-            custom_event.upcast::<Event>().fire(self.upcast());
-        }
-    }
-
     fn create_nested_browsing_context(&self) {
         // Synchronously create a new context and navigate it to about:blank.
         let url = ServoUrl::parse("about:blank").unwrap();
         let document = document_from_node(self);
         let window = window_from_node(self);
         let pipeline_id = Some(window.upcast::<GlobalScope>().pipeline_id());
         let load_data = LoadData::new(url, pipeline_id, document.get_referrer_policy(), Some(document.url().clone()));
-        let (browsing_context_id, top_level_browsing_context_id) = if self.Mozbrowser() {
-            let top_level_browsing_context_id = TopLevelBrowsingContextId::new();
-            (BrowsingContextId::from(top_level_browsing_context_id), top_level_browsing_context_id)
-        } else {
-            (BrowsingContextId::new(), window.window_proxy().top_level_browsing_context_id())
-        };
+        let browsing_context_id = BrowsingContextId::new();
+        let top_level_browsing_context_id = window.window_proxy().top_level_browsing_context_id();
         self.pipeline_id.set(None);
         self.pending_pipeline_id.set(None);
         self.top_level_browsing_context_id.set(Some(top_level_browsing_context_id));
         self.browsing_context_id.set(Some(browsing_context_id));
         self.navigate_or_reload_child_browsing_context(Some(load_data), NavigationType::InitialAboutBlank, false);
     }
 
     fn destroy_nested_browsing_context(&self) {
@@ -353,21 +313,16 @@ impl HTMLIFrameElement {
     #[inline]
     pub fn top_level_browsing_context_id(&self) -> Option<TopLevelBrowsingContextId> {
         self.top_level_browsing_context_id.get()
     }
 
     pub fn change_visibility_status(&self, visibility: bool) {
         if self.visibility.get() != visibility {
             self.visibility.set(visibility);
-
-            // Visibility changes are only exposed to Mozbrowser iframes
-            if self.Mozbrowser() {
-                self.dispatch_mozbrowser_event(MozBrowserEvent::VisibilityChange(visibility));
-            }
         }
     }
 
     pub fn set_visible(&self, visible: bool) {
         let msg = ScriptMsg::SetVisible(visible);
         let window = window_from_node(self);
         window.upcast::<GlobalScope>().script_to_constellation_chan().send(msg).unwrap();
     }
@@ -390,26 +345,16 @@ impl HTMLIFrameElement {
         let mut blocker = self.load_blocker.borrow_mut();
         LoadBlocker::terminate(&mut blocker);
 
         // TODO Step 5 - unset child document `mut iframe load` flag
 
         let window = window_from_node(self);
         window.reflow(ReflowGoal::Full, ReflowReason::IFrameLoadEvent);
     }
-
-    /// Check whether the iframe has the mozprivatebrowsing attribute set
-    pub fn privatebrowsing(&self) -> bool {
-        if self.Mozbrowser() {
-            let element = self.upcast::<Element>();
-            element.has_attribute(&LocalName::from("mozprivatebrowsing"))
-        } else {
-            false
-        }
-    }
 }
 
 pub trait HTMLIFrameElementLayoutMethods {
     fn pipeline_id(&self) -> Option<PipelineId>;
     fn browsing_context_id(&self) -> Option<BrowsingContextId>;
     fn get_width(&self) -> LengthOrPercentageOrAuto;
     fn get_height(&self) -> LengthOrPercentageOrAuto;
 }
@@ -450,127 +395,16 @@ impl HTMLIFrameElementLayoutMethods for 
                 .get_attr_for_layout(&ns!(), &local_name!("height"))
                 .map(AttrValue::as_dimension)
                 .cloned()
                 .unwrap_or(LengthOrPercentageOrAuto::Auto)
         }
     }
 }
 
-#[allow(unsafe_code)]
-pub fn build_mozbrowser_custom_event(window: &Window, event: MozBrowserEvent) -> DomRoot<CustomEvent> {
-    // TODO(gw): Support mozbrowser event types that have detail which is not a string.
-    // See https://developer.mozilla.org/en-US/docs/Web/API/Using_the_Browser_API
-    // for a list of mozbrowser events.
-    let cx = window.get_cx();
-    let _ac = JSAutoCompartment::new(cx, window.reflector().get_jsobject().get());
-    rooted!(in(cx) let mut detail = UndefinedValue());
-    let event_name = Atom::from(event.name());
-    unsafe { build_mozbrowser_event_detail(event, cx, detail.handle_mut()); }
-    CustomEvent::new(window.upcast(),
-                     event_name,
-                     true,
-                     true,
-                     detail.handle())
-}
-
-#[allow(unsafe_code)]
-unsafe fn build_mozbrowser_event_detail(event: MozBrowserEvent,
-                                        cx: *mut JSContext,
-                                        rval: MutableHandleValue) {
-    match event {
-        MozBrowserEvent::AsyncScroll | MozBrowserEvent::Close | MozBrowserEvent::ContextMenu |
-        MozBrowserEvent::LoadEnd | MozBrowserEvent::LoadStart |
-        MozBrowserEvent::Connected | MozBrowserEvent::OpenSearch  |
-        MozBrowserEvent::UsernameAndPasswordRequired => {
-            rval.set(NullValue());
-        }
-        MozBrowserEvent::Error(error_type, description, report) => {
-            BrowserElementErrorEventDetail {
-                type_: Some(DOMString::from(error_type.name())),
-                description: Some(DOMString::from(description)),
-                report: Some(DOMString::from(report)),
-                version: Some(DOMString::from_string(servo_version())),
-            }.to_jsval(cx, rval);
-        },
-        MozBrowserEvent::SecurityChange(https_state) => {
-            BrowserElementSecurityChangeDetail {
-                // https://developer.mozilla.org/en-US/docs/Web/Events/mozbrowsersecuritychange
-                state: Some(DOMString::from(match https_state {
-                    HttpsState::Modern => "secure",
-                    HttpsState::Deprecated => "broken",
-                    HttpsState::None => "insecure",
-                }.to_owned())),
-                // FIXME - Not supported yet:
-                trackingContent: None,
-                mixedContent: None,
-                trackingState: None,
-                extendedValidation: None,
-                mixedState: None,
-            }.to_jsval(cx, rval);
-        }
-        MozBrowserEvent::TitleChange(ref string) => {
-            string.to_jsval(cx, rval);
-        }
-        MozBrowserEvent::LocationChange(url, can_go_back, can_go_forward) => {
-            BrowserElementLocationChangeEventDetail {
-                url: Some(DOMString::from(url)),
-                canGoBack: Some(can_go_back),
-                canGoForward: Some(can_go_forward),
-            }.to_jsval(cx, rval);
-        }
-        MozBrowserEvent::OpenTab(url) => {
-            BrowserElementOpenTabEventDetail {
-                url: Some(DOMString::from(url)),
-            }.to_jsval(cx, rval);
-        }
-        MozBrowserEvent::OpenWindow(url, target, features) => {
-            BrowserElementOpenWindowEventDetail {
-                url: Some(DOMString::from(url)),
-                target: target.map(DOMString::from),
-                features: features.map(DOMString::from),
-            }.to_jsval(cx, rval);
-        }
-        MozBrowserEvent::IconChange(rel, href, sizes) => {
-            BrowserElementIconChangeEventDetail {
-                rel: Some(DOMString::from(rel)),
-                href: Some(DOMString::from(href)),
-                sizes: Some(DOMString::from(sizes)),
-            }.to_jsval(cx, rval);
-        }
-        MozBrowserEvent::ShowModalPrompt(prompt_type, title, message, return_value) => {
-            BrowserShowModalPromptEventDetail {
-                promptType: Some(DOMString::from(prompt_type)),
-                title: Some(DOMString::from(title)),
-                message: Some(DOMString::from(message)),
-                returnValue: Some(DOMString::from(return_value)),
-            }.to_jsval(cx, rval)
-        }
-        MozBrowserEvent::VisibilityChange(visibility) => {
-            BrowserElementVisibilityChangeEventDetail {
-                visible: Some(visibility),
-            }.to_jsval(cx, rval);
-        }
-    }
-}
-
-pub fn Navigate(iframe: &HTMLIFrameElement, direction: TraversalDirection) -> ErrorResult {
-    if iframe.Mozbrowser() {
-        if let Some(_) = iframe.top_level_browsing_context_id() {
-            let window = window_from_node(iframe);
-            let msg = ScriptMsg::TraverseHistory(direction);
-            window.upcast::<GlobalScope>().script_to_constellation_chan().send(msg).unwrap();
-            return Ok(());
-        }
-    }
-    debug!(concat!("this frame is not mozbrowser: mozbrowser attribute missing, or not a top",
-                   "level window, or mozbrowser preference not set (use --pref dom.mozbrowser.enabled)"));
-    Err(Error::NotSupported)
-}
-
 impl HTMLIFrameElementMethods for HTMLIFrameElement {
     // https://html.spec.whatwg.org/multipage/#dom-iframe-src
     make_url_getter!(Src, "src");
 
     // https://html.spec.whatwg.org/multipage/#dom-iframe-src
     make_setter!(SetSrc, "src");
 
     // https://html.spec.whatwg.org/multipage/#dom-iframe-sandbox
@@ -599,122 +433,35 @@ impl HTMLIFrameElementMethods for HTMLIF
         let current = GlobalScope::current().expect("No current global object").as_window().Document();
         if !current.origin().same_origin_domain(document.origin()) {
             return None;
         }
         // Step 5.
         Some(document)
     }
 
-    // Experimental mozbrowser implementation is based on the webidl
-    // present in the gecko source tree, and the documentation here:
-    // https://developer.mozilla.org/en-US/docs/Web/API/Using_the_Browser_API
-    // https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe#attr-mozbrowser
-    fn Mozbrowser(&self) -> bool {
-        if window_from_node(self).is_mozbrowser() {
-            let element = self.upcast::<Element>();
-            element.has_attribute(&local_name!("mozbrowser"))
-        } else {
-            false
-        }
-    }
-
-    // https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe#attr-mozbrowser
-    fn SetMozbrowser(&self, value: bool) {
-        let element = self.upcast::<Element>();
-        element.set_bool_attribute(&local_name!("mozbrowser"), value);
-    }
-
     // https://html.spec.whatwg.org/multipage/#attr-iframe-allowfullscreen
     make_bool_getter!(AllowFullscreen, "allowfullscreen");
     // https://html.spec.whatwg.org/multipage/#attr-iframe-allowfullscreen
     make_bool_setter!(SetAllowFullscreen, "allowfullscreen");
 
-    // https://developer.mozilla.org/en-US/docs/Web/API/HTMLIFrameElement/goBack
-    fn GoBack(&self) -> ErrorResult {
-        Navigate(self, TraversalDirection::Back(1))
-    }
-
-    // https://developer.mozilla.org/en-US/docs/Web/API/HTMLIFrameElement/goForward
-    fn GoForward(&self) -> ErrorResult {
-        Navigate(self, TraversalDirection::Forward(1))
-    }
-
-    // https://developer.mozilla.org/en-US/docs/Web/API/HTMLIFrameElement/reload
-    fn Reload(&self, _hard_reload: bool) -> ErrorResult {
-        if self.Mozbrowser() {
-            if self.upcast::<Node>().is_in_doc_with_browsing_context() {
-                self.navigate_or_reload_child_browsing_context(None, NavigationType::Regular, true);
-            }
-            Ok(())
-        } else {
-            debug!(concat!("this frame is not mozbrowser: mozbrowser attribute missing, or not a top",
-                "level window, or mozbrowser preference not set (use --pref dom.mozbrowser.enabled)"));
-            Err(Error::NotSupported)
-        }
-    }
-
-    // https://developer.mozilla.org/en-US/docs/Web/API/HTMLIFrameElement/setVisible
-    fn SetVisible(&self, visible: bool) -> ErrorResult {
-        if self.Mozbrowser() {
-            self.set_visible(visible);
-            Ok(())
-        } else {
-            debug!(concat!("this frame is not mozbrowser: mozbrowser attribute missing, or not a top",
-                "level window, or mozbrowser preference not set (use --pref dom.mozbrowser.enabled)"));
-            Err(Error::NotSupported)
-        }
-    }
-
-    // https://developer.mozilla.org/en-US/docs/Web/API/HTMLIFrameElement/getVisible
-    fn GetVisible(&self) -> Fallible<bool> {
-        if self.Mozbrowser() {
-            Ok(self.visibility.get())
-        } else {
-            debug!(concat!("this frame is not mozbrowser: mozbrowser attribute missing, or not a top",
-                "level window, or mozbrowser preference not set (use --pref dom.mozbrowser.enabled)"));
-            Err(Error::NotSupported)
-        }
-    }
-
-
-    // https://developer.mozilla.org/en-US/docs/Web/API/HTMLIFrameElement/stop
-    fn Stop(&self) -> ErrorResult {
-        Err(Error::NotSupported)
-    }
-
     // https://html.spec.whatwg.org/multipage/#dom-dim-width
     make_getter!(Width, "width");
     // https://html.spec.whatwg.org/multipage/#dom-dim-width
     make_dimension_setter!(SetWidth, "width");
 
     // https://html.spec.whatwg.org/multipage/#dom-dim-height
     make_getter!(Height, "height");
     // https://html.spec.whatwg.org/multipage/#dom-dim-height
     make_dimension_setter!(SetHeight, "height");
 
     // https://html.spec.whatwg.org/multipage/#other-elements,-attributes-and-apis:attr-iframe-frameborder
     make_getter!(FrameBorder, "frameborder");
     // https://html.spec.whatwg.org/multipage/#other-elements,-attributes-and-apis:attr-iframe-frameborder
     make_setter!(SetFrameBorder, "frameborder");
-
-    // check-tidy: no specs after this line
-    fn SetMozprivatebrowsing(&self, value: bool) {
-        let element = self.upcast::<Element>();
-        element.set_bool_attribute(&LocalName::from("mozprivatebrowsing"), value);
-    }
-
-    fn Mozprivatebrowsing(&self) -> bool {
-        if window_from_node(self).is_mozbrowser() {
-            let element = self.upcast::<Element>();
-            element.has_attribute(&LocalName::from("mozprivatebrowsing"))
-        } else {
-            false
-        }
-    }
 }
 
 impl VirtualMethods for HTMLIFrameElement {
     fn super_type(&self) -> Option<&VirtualMethods> {
         Some(self.upcast::<HTMLElement>() as &VirtualMethods)
     }
 
     fn attribute_mutated(&self, attr: &Attr, mutation: AttributeMutation) {
--- a/servo/components/script/dom/htmllinkelement.rs
+++ b/servo/components/script/dom/htmllinkelement.rs
@@ -19,17 +19,17 @@ use dom::element::{cors_setting_for_elem
 use dom::globalscope::GlobalScope;
 use dom::htmlelement::HTMLElement;
 use dom::node::{Node, UnbindContext, document_from_node, window_from_node};
 use dom::stylesheet::StyleSheet as DOMStyleSheet;
 use dom::virtualmethods::VirtualMethods;
 use dom_struct::dom_struct;
 use html5ever::{LocalName, Prefix};
 use net_traits::ReferrerPolicy;
-use script_traits::{MozBrowserEvent, ScriptMsg};
+use script_traits::ScriptMsg;
 use servo_arc::Arc;
 use std::borrow::ToOwned;
 use std::cell::Cell;
 use std::default::Default;
 use style::attr::AttrValue;
 use style::media_queries::parse_media_query_list;
 use style::parser::ParserContext as CssParserContext;
 use style::str::HTML_SPACE_CHARACTERS;
@@ -304,28 +304,22 @@ impl HTMLLinkElement {
         // TODO: #8085 - Don't load external stylesheets if the node's mq
         // doesn't match.
         let loader = StylesheetLoader::for_element(self.upcast());
         loader.load(StylesheetContextSource::LinkElement {
             media: Some(media),
         }, link_url, cors_setting, integrity_metadata.to_owned());
     }
 
-    fn handle_favicon_url(&self, rel: &str, href: &str, sizes: &Option<String>) {
+    fn handle_favicon_url(&self, _rel: &str, href: &str, _sizes: &Option<String>) {
         let document = document_from_node(self);
         match document.base_url().join(href) {
             Ok(url) => {
                 let event = ScriptMsg::NewFavicon(url.clone());
                 document.window().upcast::<GlobalScope>().script_to_constellation_chan().send(event).unwrap();
-
-                let mozbrowser_event = match *sizes {
-                    Some(ref sizes) => MozBrowserEvent::IconChange(rel.to_owned(), url.to_string(), sizes.to_owned()),
-                    None => MozBrowserEvent::IconChange(rel.to_owned(), url.to_string(), "".to_owned())
-                };
-                document.trigger_mozbrowser_event(mozbrowser_event);
             }
             Err(e) => debug!("Parsing url {} failed: {}", href, e)
         }
     }
 }
 
 impl StylesheetOwner for HTMLLinkElement {
     fn increment_pending_loads_count(&self) {
--- a/servo/components/script/dom/mod.rs
+++ b/servo/components/script/dom/mod.rs
@@ -284,17 +284,16 @@ pub mod eventsource;
 pub mod eventtarget;
 pub mod extendableevent;
 pub mod extendablemessageevent;
 pub mod file;
 pub mod filelist;
 pub mod filereader;
 pub mod filereadersync;
 pub mod focusevent;
-pub mod forcetouchevent;
 pub mod formdata;
 pub mod gamepad;
 pub mod gamepadbutton;
 pub mod gamepadbuttonlist;
 pub mod gamepadevent;
 pub mod gamepadlist;
 pub mod globalscope;
 pub mod hashchangeevent;
deleted file mode 100644
--- a/servo/components/script/dom/webidls/BrowserElement.webidl
+++ /dev/null
@@ -1,227 +0,0 @@
-/* This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-
-// https://developer.mozilla.org/en-US/docs/Web/API/Using_the_Browser_API
-
-callback BrowserElementNextPaintEventCallback = void ();
-
-//enum BrowserFindCaseSensitivity { "case-sensitive", "case-insensitive" };
-//enum BrowserFindDirection { "forward", "backward" };
-
-//dictionary BrowserElementDownloadOptions {
-//  DOMString? filename;
-//  DOMString? referrer;
-//};
-
-//dictionary BrowserElementExecuteScriptOptions {
-//  DOMString? url;
-//  DOMString? origin;
-//};
-
-[NoInterfaceObject, Exposed=(Window,Worker)]
-interface BrowserElement {
-};
-
-dictionary BrowserElementSecurityChangeDetail {
-
-  // state:
-  //   "insecure" indicates that the data corresponding to
-  //     the request was received over an insecure channel.
-  //
-  //   "broken" indicates an unknown security state.  This
-  //     may mean that the request is being loaded as part
-  //     of a page in which some content was received over
-  //     an insecure channel.
-  //
-  //   "secure" indicates that the data corresponding to the
-  //     request was received over a secure channel.
-  DOMString state;
-
-  // trackingState:
-  //   "loaded_tracking_content": tracking content has been loaded.
-  //   "blocked_tracking_content": tracking content has been blocked from loading.
-  DOMString trackingState;
-
-  // mixedState:
-  //   "blocked_mixed_active_content": Mixed active content has been blocked from loading.
-  //   "loaded_mixed_active_content": Mixed active content has been loaded.
-  DOMString mixedState;
-
-  boolean extendedValidation;
-  boolean trackingContent;
-  boolean mixedContent;
-};
-
-dictionary BrowserElementErrorEventDetail {
-  // https://developer.mozilla.org/en-US/docs/Web/Events/mozbrowsererror
-  // just requires a "type" field, but we also provide
-  // an optional human-readable description, and
-  // an optional machine-readable report (e.g. a backtrace for panics)
-  DOMString type;
-  DOMString description;
-  DOMString report;
-  DOMString version;
-};
-
-dictionary BrowserElementLocationChangeEventDetail {
-  DOMString url;
-  boolean canGoBack;
-  boolean canGoForward;
-};
-
-dictionary BrowserElementIconChangeEventDetail {
-  DOMString rel;
-  DOMString href;
-  DOMString sizes;
-};
-
-dictionary BrowserShowModalPromptEventDetail {
-  DOMString promptType;
-  DOMString title;
-  DOMString message;
-  DOMString returnValue;
-  // TODO(simartin) unblock() callback
-};
-
-dictionary BrowserElementOpenTabEventDetail {
-  // https://developer.mozilla.org/en-US/docs/Web/Events/mozbrowseropentab
-  DOMString url;
-};
-
-dictionary BrowserElementOpenWindowEventDetail {
-  // https://developer.mozilla.org/en-US/docs/Web/Events/mozbrowseropenwindow
-  DOMString url;
-  DOMString target;
-  DOMString features;
-  // Element frameElement;
-};
-
-dictionary BrowserElementVisibilityChangeEventDetail {
-  boolean visible;
-};
-
-BrowserElement implements BrowserElementCommon;
-BrowserElement implements BrowserElementPrivileged;
-
-[NoInterfaceObject, Exposed=(Window,Worker)]
-interface BrowserElementCommon {
-  [Throws,
-   Pref="dom.mozbrowser.enabled"]
-  void setVisible(boolean visible);
-
-  [Throws,
-   Pref="dom.mozbrowser.enabled"]
-  boolean getVisible();
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //void setActive(boolean active);
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //boolean getActive();
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //void addNextPaintListener(BrowserElementNextPaintEventCallback listener);
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //void removeNextPaintListener(BrowserElementNextPaintEventCallback listener);
-};
-
-[NoInterfaceObject, Exposed=(Window,Worker)]
-interface BrowserElementPrivileged {
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //void sendMouseEvent(DOMString type,
-  //                    unsigned long x,
-  //                    unsigned long y,
-  //                    unsigned long button,
-  //                    unsigned long clickCount,
-  //                    unsigned long modifiers);
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled",
-  // Func="TouchEvent::PrefEnabled"]
-  //void sendTouchEvent(DOMString type,
-  //                    sequence<unsigned long> identifiers,
-  //                    sequence<long> x,
-  //                    sequence<long> y,
-  //                    sequence<unsigned long> rx,
-  //                    sequence<unsigned long> ry,
-  //                    sequence<float> rotationAngles,
-  //                    sequence<float> forces,
-  //                    unsigned long count,
-  //                    unsigned long modifiers);
-
-  [Func="::dom::window::Window::global_is_mozbrowser", Throws]
-  void goBack();
-
-  [Func="::dom::window::Window::global_is_mozbrowser", Throws]
-  void goForward();
-
-  [Func="::dom::window::Window::global_is_mozbrowser", Throws]
-  void reload(optional boolean hardReload = false);
-
-  [Func="::dom::window::Window::global_is_mozbrowser", Throws]
-  void stop();
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //DOMRequest download(DOMString url,
-  //                    optional BrowserElementDownloadOptions options);
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //DOMRequest purgeHistory();
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //DOMRequest getScreenshot([EnforceRange] unsigned long width,
-  //                         [EnforceRange] unsigned long height,
-  //                         optional DOMString mimeType="");
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //void zoom(float zoom);
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //DOMRequest getCanGoBack();
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //DOMRequest getCanGoForward();
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //DOMRequest getContentDimensions();
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //DOMRequest setInputMethodActive(boolean isActive);
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //void setNFCFocus(boolean isFocus);
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //void findAll(DOMString searchString, BrowserFindCaseSensitivity caseSensitivity);
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //void findNext(BrowserFindDirection direction);
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //void clearMatch();
-
-  //[Throws,
-  // Pref="dom.mozBrowserFramesEnabled"]
-  //DOMRequest executeScript(DOMString script,
-  //                         optional BrowserElementExecuteScriptOptions options);
-
-};
deleted file mode 100644
--- a/servo/components/script/dom/webidls/ForceTouchEvent.webidl
+++ /dev/null
@@ -1,34 +0,0 @@
-/* This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-
-// https://developer.apple.com/library/mac/documentation/AppleApplications/Conceptual/SafariJSProgTopics/RespondingtoForceTouchEventsfromJavaScript.html
-
-/**
- * Events: (copy/paste from apple.com)
- *
- *  webkitmouseforcewillbegin: This event occurs immediately before the mousedown event. It allows you to
- *   prevent the default system behavior, such as displaying a dictionary window when force clicking on a
- *   word, in order to perform a custom action instead. To prevent the default system behavior, call the
- *   preventDefault() method on the event.
- *  webkitmouseforcedown: This event occurs after the mousedown event, once enough force has been applied
- *   to register as a force click. The user receives haptic feedback representing the force click when this
- *   event occurs.
- *  webkitmouseforceup: This event occurs after a webkitmouseforcedown event, once enough force has been
- *   released to exit the force click operation. The user receives haptic feedback representing the exit
- *   from force click when this event occurs.
- *  webkitmouseforcechanged: This event occurs whenever a change in trackpad force is detected between the
- *   mousedown and mouseup events.
- *
- */
-
-
-[Pref="dom.forcetouch.enabled"]
-interface ForceTouchEvent : UIEvent {
-    // Represents the amount of force required to perform a regular click.
-    readonly attribute float SERVO_FORCE_AT_MOUSE_DOWN;
-    // Represents the force required to perform a force click.
-    readonly attribute float SERVO_FORCE_AT_FORCE_MOUSE_DOWN;
-    // force level
-    readonly attribute float servoForce;
-};
--- a/servo/components/script/dom/webidls/HTMLIFrameElement.webidl
+++ b/servo/components/script/dom/webidls/HTMLIFrameElement.webidl
@@ -41,18 +41,8 @@ partial interface HTMLIFrameElement {
   // [CEReactions]
   //         attribute DOMString longDesc;
 
   // [CEReactions, TreatNullAs=EmptyString]
   // attribute DOMString marginHeight;
   // [CEReactions, TreatNullAs=EmptyString]
   // attribute DOMString marginWidth;
 };
-
-partial interface HTMLIFrameElement {
-    [CEReactions, Func="::dom::window::Window::global_is_mozbrowser"]
-    attribute boolean mozbrowser;
-
-    [CEReactions, Func="::dom::window::Window::global_is_mozbrowser"]
-    attribute boolean mozprivatebrowsing;
-};
-
-HTMLIFrameElement implements BrowserElement;
--- a/servo/components/script/dom/webidls/Window.webidl
+++ b/servo/components/script/dom/webidls/Window.webidl
@@ -159,18 +159,16 @@ partial interface Window {
   readonly attribute double devicePixelRatio;
 };
 
 // Proprietary extensions.
 partial interface Window {
   void debug(DOMString arg);
   void gc();
   void trap();
-  [Func="Window::global_is_mozbrowser", Throws]
-  void openURLInDefaultBrowser(DOMString href);
 };
 
 // WebDriver extensions
 partial interface Window {
   // Shouldn't be public, but just to make things work for now
   void webdriverCallback(optional any result);
   void webdriverTimeout();
 };
--- a/servo/components/script/dom/window.rs
+++ b/servo/components/script/dom/window.rs
@@ -27,20 +27,18 @@ use dom::bindings::structuredclone::Stru
 use dom::bindings::trace::RootedTraceableBox;
 use dom::bindings::utils::{GlobalStaticData, WindowProxyHandler};
 use dom::bluetooth::BluetoothExtraPermissionData;
 use dom::crypto::Crypto;
 use dom::cssstyledeclaration::{CSSModificationAccess, CSSStyleDeclaration, CSSStyleOwner};
 use dom::customelementregistry::CustomElementRegistry;
 use dom::document::{AnimationFrameCallback, Document};
 use dom::element::Element;
-use dom::event::Event;
 use dom::globalscope::GlobalScope;
 use dom::history::History;
-use dom::htmliframeelement::build_mozbrowser_custom_event;
 use dom::location::Location;
 use dom::mediaquerylist::{MediaQueryList, WeakMediaQueryListVec};
 use dom::messageevent::MessageEvent;
 use dom::navigator::Navigator;
 use dom::node::{Node, NodeDamage, document_from_node, from_untrusted_node_address};
 use dom::performance::Performance;
 use dom::promise::Promise;
 use dom::screen::Screen;
@@ -49,46 +47,44 @@ use dom::testrunner::TestRunner;
 use dom::windowproxy::WindowProxy;
 use dom::worklet::Worklet;
 use dom::workletglobalscope::WorkletGlobalScopeType;
 use dom_struct::dom_struct;
 use euclid::{Point2D, Vector2D, Rect, Size2D};
 use fetch;
 use ipc_channel::ipc::{self, IpcSender};
 use ipc_channel::router::ROUTER;
-use js::jsapi::{HandleObject, HandleValue, JSAutoCompartment, JSContext};
+use js::jsapi::{HandleValue, JSAutoCompartment, JSContext};
 use js::jsapi::{JS_GC, JS_GetRuntime};
 use js::jsval::UndefinedValue;
 use layout_image::fetch_image_for_layout;
 use microtask::MicrotaskQueue;
-use msg::constellation_msg::{FrameType, PipelineId};
+use msg::constellation_msg::PipelineId;
 use net_traits::{ResourceThreads, ReferrerPolicy};
 use net_traits::image_cache::{ImageCache, ImageResponder, ImageResponse};
 use net_traits::image_cache::{PendingImageId, PendingImageResponse};
 use net_traits::storage_thread::StorageType;
 use num_traits::ToPrimitive;
-use open;
 use profile_traits::mem::ProfilerChan as MemProfilerChan;
 use profile_traits::time::ProfilerChan as TimeProfilerChan;
 use script_layout_interface::{TrustedNodeAddress, PendingImageState};
 use script_layout_interface::message::{Msg, Reflow, ReflowGoal, ScriptReflow};
 use script_layout_interface::reporter::CSSErrorReporter;
 use script_layout_interface::rpc::{ContentBoxResponse, ContentBoxesResponse, LayoutRPC};
 use script_layout_interface::rpc::{NodeScrollIdResponse, ResolvedStyleResponse, TextIndexResponse};
 use script_runtime::{CommonScriptMsg, ScriptChan, ScriptPort, ScriptThreadEventCategory, Runtime};
 use script_thread::{ImageCacheMsg, MainThreadScriptChan, MainThreadScriptMsg};
 use script_thread::{ScriptThread, SendableMainThreadScriptChan};
-use script_traits::{ConstellationControlMsg, DocumentState, LoadData, MozBrowserEvent};
+use script_traits::{ConstellationControlMsg, DocumentState, LoadData};
 use script_traits::{ScriptToConstellationChan, ScriptMsg, ScrollState, TimerEvent, TimerEventId};
 use script_traits::{TimerSchedulerMsg, UntrustedNodeAddress, WindowSizeData, WindowSizeType};
 use script_traits::webdriver_msg::{WebDriverJSError, WebDriverJSResult};
 use selectors::attr::CaseSensitivity;
 use servo_arc;
 use servo_config::opts;
-use servo_config::prefs::PREFS;
 use servo_geometry::{f32_rect_to_au_rect, MaxRect};
 use servo_url::{Host, MutableOrigin, ImmutableOrigin, ServoUrl};
 use std::borrow::ToOwned;
 use std::cell::Cell;
 use std::collections::{HashMap, HashSet};
 use std::collections::hash_map::Entry;
 use std::default::Default;
 use std::env;
@@ -195,17 +191,17 @@ pub struct Window {
     devtools_markers: DomRefCell<HashSet<TimelineMarkerType>>,
     #[ignore_malloc_size_of = "channels are hard"]
     devtools_marker_sender: DomRefCell<Option<IpcSender<Option<TimelineMarker>>>>,
 
     /// Pending resize event, if any.
     resize_event: Cell<Option<(WindowSizeData, WindowSizeType)>>,
 
     /// Parent id associated with this page, if any.
-    parent_info: Option<(PipelineId, FrameType)>,
+    parent_info: Option<PipelineId>,
 
     /// Global static data related to the DOM.
     dom_static: GlobalStaticData,
 
     /// The JavaScript runtime.
     #[ignore_malloc_size_of = "Rc<T> is hard"]
     js_runtime: DomRefCell<Option<Rc<Runtime>>>,
 
@@ -338,17 +334,17 @@ impl Window {
     pub fn performance_timeline_task_source(&self) -> PerformanceTimelineTaskSource {
         self.performance_timeline_task_source.clone()
     }
 
     pub fn main_thread_script_chan(&self) -> &Sender<MainThreadScriptMsg> {
         &self.script_chan.0
     }
 
-    pub fn parent_info(&self) -> Option<(PipelineId, FrameType)> {
+    pub fn parent_info(&self) -> Option<PipelineId> {
         self.parent_info
     }
 
     pub fn new_script_pair(&self) -> (Box<ScriptChan + Send>, Box<ScriptPort + Send>) {
         let (tx, rx) = channel();
         (Box::new(SendableMainThreadScriptChan(tx)), Box::new(rx))
     }
 
@@ -515,17 +511,17 @@ pub fn base64_atob(input: DOMString) -> 
 impl WindowMethods for Window {
     // https://html.spec.whatwg.org/multipage/#dom-alert
     fn Alert_(&self) {
         self.Alert(DOMString::new());
     }
 
     // https://html.spec.whatwg.org/multipage/#dom-alert
     fn Alert(&self, s: DOMString) {
-        // Right now, just print to the console
+        // Print to the console.
         // Ensure that stderr doesn't trample through the alert() we use to
         // communicate test results (see executorservo.py in wptrunner).
         {
             let stderr = stderr();
             let mut stderr = stderr.lock();
             let stdout = stdout();
             let mut stdout = stdout.lock();
             writeln!(&mut stdout, "ALERT: {}", s).unwrap();
@@ -987,27 +983,16 @@ impl WindowMethods for Window {
         self.status.borrow().clone()
     }
 
     // https://html.spec.whatwg.org/multipage/#dom-window-status
     fn SetStatus(&self, status: DOMString) {
         *self.status.borrow_mut() = status
     }
 
-    // check-tidy: no specs after this line
-    fn OpenURLInDefaultBrowser(&self, href: DOMString) -> ErrorResult {
-        let url = ServoUrl::parse(&href).map_err(|e| {
-            Error::Type(format!("Couldn't parse URL: {}", e))
-        })?;
-        match open::that(url.as_str()) {
-            Ok(_) => Ok(()),
-            Err(e) => Err(Error::Type(format!("Couldn't open URL: {}", e))),
-        }
-    }
-
     // https://drafts.csswg.org/cssom-view/#dom-window-matchmedia
     fn MatchMedia(&self, query: DOMString) -> DomRoot<MediaQueryList> {
         let mut input = ParserInput::new(&query);
         let mut parser = Parser::new(&mut input);
         let url = self.get_url();
         let quirks_mode = self.Document().quirks_mode();
         let context = CssParserContext::new_for_cssom(&url, Some(CssRuleType::Media),
                                                       ParsingMode::DEFAULT,
@@ -1677,41 +1662,17 @@ impl Window {
     }
 
     pub fn is_alive(&self) -> bool {
         self.current_state.get() == WindowState::Alive
     }
 
     // https://html.spec.whatwg.org/multipage/#top-level-browsing-context
     pub fn is_top_level(&self) -> bool {
-        match self.parent_info {
-            Some((_, FrameType::IFrame)) => false,
-            _ => true,
-        }
-    }
-
-    /// Returns whether this window is mozbrowser.
-    pub fn is_mozbrowser(&self) -> bool {
-        PREFS.is_mozbrowser_enabled() && self.parent_info().is_none()
-    }
-
-    /// Returns whether mozbrowser is enabled and `obj` has been created
-    /// in a top-level `Window` global.
-    #[allow(unsafe_code)]
-    pub unsafe fn global_is_mozbrowser(_: *mut JSContext, obj: HandleObject) -> bool {
-        GlobalScope::from_object(obj.get())
-            .downcast::<Window>()
-            .map_or(false, |window| window.is_mozbrowser())
-    }
-
-    #[allow(unsafe_code)]
-    pub fn dispatch_mozbrowser_event(&self, event: MozBrowserEvent) {
-        assert!(PREFS.is_mozbrowser_enabled());
-        let custom_event = build_mozbrowser_custom_event(&self, event);
-        custom_event.upcast::<Event>().fire(self.upcast());
+        self.parent_info.is_none()
     }
 
     pub fn evaluate_media_queries_and_report_changes(&self) {
         self.media_query_lists.evaluate_and_report_changes();
     }
 
     /// Slow down/speed up timers based on visibility.
     pub fn alter_resource_utilization(&self, visible: bool) {
@@ -1764,17 +1725,17 @@ impl Window {
         time_profiler_chan: TimeProfilerChan,
         devtools_chan: Option<IpcSender<ScriptToDevtoolsControlMsg>>,
         constellation_chan: ScriptToConstellationChan,
         control_chan: IpcSender<ConstellationControlMsg>,
         scheduler_chan: IpcSender<TimerSchedulerMsg>,
         timer_event_chan: IpcSender<TimerEvent>,
         layout_chan: Sender<Msg>,
         pipelineid: PipelineId,
-        parent_info: Option<(PipelineId, FrameType)>,
+        parent_info: Option<PipelineId>,
         window_size: Option<WindowSizeData>,
         origin: MutableOrigin,
         navigation_start: u64,
         navigation_start_precise: u64,
         webgl_chan: WebGLChan,
         webvr_chan: Option<IpcSender<WebVRMsg>>,
         microtask_queue: Rc<MicrotaskQueue>,
         webrender_document: DocumentId,
--- a/servo/components/script/dom/xmlhttprequest.rs
+++ b/servo/components/script/dom/xmlhttprequest.rs
@@ -55,17 +55,16 @@ use js::typedarray::{ArrayBuffer, Create
 use net_traits::{FetchChannels, FetchMetadata, FilteredMetadata};
 use net_traits::{FetchResponseListener, NetworkError, ReferrerPolicy};
 use net_traits::CoreResourceMsg::Fetch;
 use net_traits::request::{CredentialsMode, Destination, RequestInit, RequestMode};
 use net_traits::trim_http_whitespace;
 use network_listener::{NetworkListener, PreInvoke};
 use script_traits::DocumentActivity;
 use servo_atoms::Atom;
-use servo_config::prefs::PREFS;
 use servo_url::ServoUrl;
 use std::borrow::ToOwned;
 use std::cell::Cell;
 use std::default::Default;
 use std::ptr;
 use std::ptr::NonNull;
 use std::slice;
 use std::str;
@@ -567,30 +566,16 @@ impl XMLHttpRequestMethods for XMLHttpRe
             CredentialsMode::CredentialsSameOrigin
         };
         let use_url_credentials = if let Some(ref url) = *self.request_url.borrow() {
             !url.username().is_empty() || url.password().is_some()
         } else {
             unreachable!()
         };
 
-        let bypass_cross_origin_check = {
-            // We want to be able to do cross-origin requests in browser.html.
-            // If the XHR happens in a top level window and the mozbrowser
-            // preference is enabled, we allow bypassing the CORS check.
-            // This is a temporary measure until we figure out Servo privilege
-            // story. See https://github.com/servo/servo/issues/9582
-            if let Some(win) = DomRoot::downcast::<Window>(self.global()) {
-                let is_root_pipeline = win.parent_info().is_none();
-                is_root_pipeline && PREFS.is_mozbrowser_enabled()
-            } else {
-                false
-            }
-        };
-
         let mut request = RequestInit {
             method: self.request_method.borrow().clone(),
             url: self.request_url.borrow().clone().unwrap(),
             headers: (*self.request_headers.borrow()).clone(),
             unsafe_request: true,
             // XXXManishearth figure out how to avoid this clone
             body: extracted_or_serialized.as_ref().map(|e| e.0.clone()),
             // XXXManishearth actually "subresource", but it doesn't exist
@@ -603,20 +588,16 @@ impl XMLHttpRequestMethods for XMLHttpRe
             use_url_credentials: use_url_credentials,
             origin: self.global().origin().immutable().clone(),
             referrer_url: self.referrer_url.clone(),
             referrer_policy: self.referrer_policy.clone(),
             pipeline_id: Some(self.global().pipeline_id()),
             .. RequestInit::default()
         };
 
-        if bypass_cross_origin_check {
-            request.mode = RequestMode::Navigate;
-        }
-
         // step 4 (second half)
         match extracted_or_serialized {
             Some((_, ref content_type)) => {
                 let encoding = match data {
                     Some(DocumentOrBodyInit::String(_)) | Some(DocumentOrBodyInit::Document(_)) =>
                     // XHR spec differs from http, and says UTF-8 should be in capitals,
                     // instead of "utf-8", which is what Hyper defaults to. So not
                     // using content types provided by Hyper.
--- a/servo/components/script/lib.rs
+++ b/servo/components/script/lib.rs
@@ -65,17 +65,16 @@ extern crate mime;
 extern crate mime_guess;
 extern crate mitochondria;
 #[macro_use]
 extern crate mozjs as js;
 extern crate msg;
 extern crate net_traits;
 extern crate num_traits;
 extern crate offscreen_gl_context;
-extern crate open;
 extern crate parking_lot;
 extern crate phf;
 #[macro_use]
 extern crate profile_traits;
 extern crate ref_filter_map;
 extern crate ref_slice;
 extern crate regex;
 extern crate script_layout_interface;
--- a/servo/components/script/script_thread.rs
+++ b/servo/components/script/script_thread.rs
@@ -72,37 +72,36 @@ use ipc_channel::router::ROUTER;
 use js::glue::GetWindowProxyClass;
 use js::jsapi::{JSAutoCompartment, JSContext, JS_SetWrapObjectCallbacks};
 use js::jsapi::{JSTracer, SetWindowProxyClass};
 use js::jsval::UndefinedValue;
 use malloc_size_of::MallocSizeOfOps;
 use mem::malloc_size_of_including_self;
 use metrics::{MAX_TASK_NS, PaintTimeMetrics};
 use microtask::{MicrotaskQueue, Microtask};
-use msg::constellation_msg::{BrowsingContextId, FrameType, PipelineId, PipelineNamespace, TopLevelBrowsingContextId};
+use msg::constellation_msg::{BrowsingContextId, PipelineId, PipelineNamespace, TopLevelBrowsingContextId};
 use net_traits::{FetchMetadata, FetchResponseListener, FetchResponseMsg};
 use net_traits::{Metadata, NetworkError, ReferrerPolicy, ResourceThreads};
 use net_traits::image_cache::{ImageCache, PendingImageResponse};
 use net_traits::request::{CredentialsMode, Destination, RedirectMode, RequestInit};
 use net_traits::storage_thread::StorageType;
 use profile_traits::mem::{self, OpaqueSender, Report, ReportKind, ReportsChan};
 use profile_traits::time::{self, ProfilerCategory, profile};
 use script_layout_interface::message::{self, Msg, NewLayoutThreadInfo, ReflowGoal};
 use script_runtime::{CommonScriptMsg, ScriptChan, ScriptThreadEventCategory};
 use script_runtime::{ScriptPort, get_reports, new_rt_and_cx, Runtime};
 use script_traits::{CompositorEvent, ConstellationControlMsg};
 use script_traits::{DiscardBrowsingContext, DocumentActivity, EventResult};
 use script_traits::{InitialScriptState, JsEvalResult, LayoutMsg, LoadData};
-use script_traits::{MouseButton, MouseEventType, MozBrowserEvent, NewLayoutInfo};
+use script_traits::{MouseButton, MouseEventType, NewLayoutInfo};
 use script_traits::{ProgressiveWebMetricType, Painter, ScriptMsg, ScriptThreadFactory};
 use script_traits::{ScriptToConstellationChan, TimerEvent, TimerSchedulerMsg};
 use script_traits::{TimerSource, TouchEventType, TouchId, UntrustedNodeAddress};
 use script_traits::{UpdatePipelineIdReason, WindowSizeData, WindowSizeType};
-use script_traits::CompositorEvent::{KeyEvent, MouseButtonEvent, MouseMoveEvent, ResizeEvent};
-use script_traits::CompositorEvent::{TouchEvent, TouchpadPressureEvent};
+use script_traits::CompositorEvent::{KeyEvent, MouseButtonEvent, MouseMoveEvent, ResizeEvent, TouchEvent};
 use script_traits::webdriver_msg::WebDriverScriptCommand;
 use serviceworkerjob::{Job, JobQueue};
 use servo_atoms::Atom;
 use servo_config::opts;
 use servo_url::{ImmutableOrigin, MutableOrigin, ServoUrl};
 use std::cell::Cell;
 use std::collections::{hash_map, HashMap, HashSet};
 use std::default::Default;
@@ -149,17 +148,17 @@ pub unsafe fn trace_thread(tr: *mut JSTr
 struct InProgressLoad {
     /// The pipeline which requested this load.
     pipeline_id: PipelineId,
     /// The browsing context being loaded into.
     browsing_context_id: BrowsingContextId,
     /// The top level ancestor browsing context.
     top_level_browsing_context_id: TopLevelBrowsingContextId,
     /// The parent pipeline and frame type associated with this load, if any.
-    parent_info: Option<(PipelineId, FrameType)>,
+    parent_info: Option<PipelineId>,
     /// The current window size associated with this pipeline.
     window_size: Option<WindowSizeData>,
     /// Channel to the layout thread associated with this pipeline.
     layout_chan: Sender<message::Msg>,
     /// The activity level of the document (inactive, active or fully active).
     activity: DocumentActivity,
     /// Window is visible.
     is_visible: bool,
@@ -175,17 +174,17 @@ struct InProgressLoad {
     canceller: FetchCanceller,
 }
 
 impl InProgressLoad {
     /// Create a new InProgressLoad object.
     fn new(id: PipelineId,
            browsing_context_id: BrowsingContextId,
            top_level_browsing_context_id: TopLevelBrowsingContextId,
-           parent_info: Option<(PipelineId, FrameType)>,
+           parent_info: Option<PipelineId>,
            layout_chan: Sender<message::Msg>,
            window_size: Option<WindowSizeData>,
            url: ServoUrl,
            origin: MutableOrigin) -> InProgressLoad {
         let current_time = get_time();
         let navigation_start_precise = precise_time_ns();
         layout_chan.send(message::Msg::SetNavigationStart(navigation_start_precise)).unwrap();
         InProgressLoad {
@@ -976,17 +975,17 @@ impl ScriptThread {
                         new_layout_info)) => {
                     let pipeline_id = new_layout_info.new_pipeline_id;
                     self.profile_event(ScriptThreadEventCategory::AttachLayout, Some(pipeline_id), || {
                         // If this is an about:blank load, it must share the creator's origin.
                         // This must match the logic in the constellation when creating a new pipeline
                         let origin = if new_layout_info.load_data.url.as_str() != "about:blank" {
                             MutableOrigin::new(new_layout_info.load_data.url.origin())
                         } else if let Some(parent) = new_layout_info.parent_info
-                                .and_then(|(pipeline_id, _)| self.documents.borrow()
+                                .and_then(|pipeline_id| self.documents.borrow()
                                 .find_document(pipeline_id)) {
                             parent.origin().clone()
                         } else if let Some(creator) = new_layout_info.load_data.creator_pipeline_id
                                 .and_then(|pipeline_id| self.documents.borrow()
                                 .find_document(pipeline_id)) {
                             creator.origin().clone()
                         } else {
                             MutableOrigin::new(ImmutableOrigin::new_opaque())
@@ -1164,17 +1163,16 @@ impl ScriptThread {
                     Viewport(id, ..) => Some(id),
                     SetScrollState(id, ..) => Some(id),
                     GetTitle(id) => Some(id),
                     SetDocumentActivity(id, ..) => Some(id),
                     ChangeFrameVisibilityStatus(id, ..) => Some(id),
                     NotifyVisibilityChange(id, ..) => Some(id),
                     Navigate(id, ..) => Some(id),
                     PostMessage(id, ..) => Some(id),
-                    MozBrowserEvent(id, ..) => Some(id),
                     UpdatePipelineId(_, _, id, _) => Some(id),
                     FocusIFrame(id, ..) => Some(id),
                     WebDriverScriptCommand(id, ..) => Some(id),
                     TickAllAnimations(id) => Some(id),
                     // FIXME https://github.com/servo/servo/issues/15079
                     TransitionEnd(..) => None,
                     WebFontLoaded(id) => Some(id),
                     DispatchIFrameLoadEvent { target: _, parent: id, child: _ } => Some(id),
@@ -1284,22 +1282,16 @@ impl ScriptThread {
             ConstellationControlMsg::SetDocumentActivity(pipeline_id, activity) =>
                 self.handle_set_document_activity_msg(pipeline_id, activity),
             ConstellationControlMsg::ChangeFrameVisibilityStatus(pipeline_id, visible) =>
                 self.handle_visibility_change_msg(pipeline_id, visible),
             ConstellationControlMsg::NotifyVisibilityChange(parent_pipeline_id, browsing_context_id, visible) =>
                 self.handle_visibility_change_complete_msg(parent_pipeline_id, browsing_context_id, visible),
             ConstellationControlMsg::PostMessage(pipeline_id, origin, data) =>
                 self.handle_post_message_msg(pipeline_id, origin, data),
-            ConstellationControlMsg::MozBrowserEvent(parent_pipeline_id,
-                                                     top_level_browsing_context_id,
-                                                     event) =>
-                self.handle_mozbrowser_event_msg(parent_pipeline_id,
-                                                 top_level_browsing_context_id,
-                                                 event),
             ConstellationControlMsg::UpdatePipelineId(parent_pipeline_id,
                                                       browsing_context_id,
                                                       new_pipeline_id,
                                                       reason) =>
                 self.handle_update_pipeline_id(parent_pipeline_id,
                                                browsing_context_id,
                                                new_pipeline_id,
                                                reason),
@@ -1688,37 +1680,16 @@ impl ScriptThread {
 
     fn handle_post_message_msg(&self, pipeline_id: PipelineId, origin: Option<ImmutableOrigin>, data: Vec<u8>) {
         match { self.documents.borrow().find_window(pipeline_id) } {
             None => return warn!("postMessage after pipeline {} closed.", pipeline_id),
             Some(window) => window.post_message(origin, StructuredCloneData::Vector(data)),
         }
     }
 
-    /// Handles a mozbrowser event, for example see:
-    /// <https://developer.mozilla.org/en-US/docs/Web/Events/mozbrowserloadstart>
-    fn handle_mozbrowser_event_msg(&self,
-                                   parent_pipeline_id: PipelineId,
-                                   top_level_browsing_context_id: Option<TopLevelBrowsingContextId>,
-                                   event: MozBrowserEvent) {
-        let doc = match { self.documents.borrow().find_document(parent_pipeline_id) } {
-            None => return warn!("Mozbrowser event after pipeline {} closed.", parent_pipeline_id),
-            Some(doc) => doc,
-        };
-
-        match top_level_browsing_context_id {
-            None => doc.window().dispatch_mozbrowser_event(event),
-            Some(top_level_browsing_context_id) => match doc.find_mozbrowser_iframe(top_level_browsing_context_id) {
-                None => warn!("Mozbrowser event after iframe {}/{} closed.",
-                              parent_pipeline_id, top_level_browsing_context_id),
-                Some(frame_element) => frame_element.dispatch_mozbrowser_event(event),
-            },
-        }
-    }
-
     fn handle_update_pipeline_id(&self,
                                  parent_pipeline_id: PipelineId,
                                  browsing_context_id: BrowsingContextId,
                                  new_pipeline_id: PipelineId,
                                  reason: UpdatePipelineIdReason) {
         let frame_element = self.documents.borrow().find_iframe(parent_pipeline_id, browsing_context_id);
         if let Some(frame_element) = frame_element {
             frame_element.update_pipeline_id(new_pipeline_id, reason);
@@ -2022,17 +1993,17 @@ impl ScriptThread {
 
     fn ask_constellation_for_browsing_context_id(&self, pipeline_id: PipelineId) -> Option<BrowsingContextId> {
         let (result_sender, result_receiver) = ipc::channel().unwrap();
         let msg = ScriptMsg::GetBrowsingContextId(pipeline_id, result_sender);
         self.script_sender.send((pipeline_id, msg)).expect("Failed to send to constellation.");
         result_receiver.recv().expect("Failed to get frame id from constellation.")
     }
 
-    fn ask_constellation_for_parent_info(&self, pipeline_id: PipelineId) -> Option<(PipelineId, FrameType)> {
+    fn ask_constellation_for_parent_info(&self, pipeline_id: PipelineId) -> Option<PipelineId> {
         let (result_sender, result_receiver) = ipc::channel().unwrap();
         let msg = ScriptMsg::GetParentInfo(pipeline_id, result_sender);
         self.script_sender.send((pipeline_id, msg)).expect("Failed to send to constellation.");
         result_receiver.recv().expect("Failed to get frame id from constellation.")
     }
 
     // Get the browsing context for a pipeline that may exist in another
     // script thread.  If the browsing context already exists in the
@@ -2045,22 +2016,19 @@ impl ScriptThread {
                            top_level_browsing_context_id: TopLevelBrowsingContextId,
                            pipeline_id: PipelineId)
                            -> Option<DomRoot<WindowProxy>>
     {
         let browsing_context_id = self.ask_constellation_for_browsing_context_id(pipeline_id)?;
         if let Some(window_proxy) = self.window_proxies.borrow().get(&browsing_context_id) {
             return Some(DomRoot::from_ref(window_proxy));
         }
-        let parent = match self.ask_constellation_for_parent_info(pipeline_id) {
-            Some((parent_id, FrameType::IFrame)) => self.remote_window_proxy(global_to_clone,
-                                                                             top_level_browsing_context_id,
-                                                                             parent_id),
-            _ => None,
-        };
+        let parent = self.ask_constellation_for_parent_info(pipeline_id).and_then(|parent_id| {
+            self.remote_window_proxy(global_to_clone, top_level_browsing_context_id, parent_id)
+        });
         let window_proxy = WindowProxy::new_dissimilar_origin(global_to_clone,
                                                               browsing_context_id,
                                                               top_level_browsing_context_id,
                                                               parent.r());
         self.window_proxies.borrow_mut().insert(browsing_context_id, Dom::from_ref(&*window_proxy));
         Some(window_proxy)
     }
 
@@ -2069,32 +2037,31 @@ impl ScriptThread {
     // `window_proxies` map, we return it, otherwise we recursively
     // get the browsing context for the parent if there is one,
     // construct a new similar-origin browsing context, add it
     // to the `window_proxies` map, and return it.
     fn local_window_proxy(&self,
                           window: &Window,
                           browsing_context_id: BrowsingContextId,
                           top_level_browsing_context_id: TopLevelBrowsingContextId,
-                          parent_info: Option<(PipelineId, FrameType)>)
+                          parent_info: Option<PipelineId>)
                           -> DomRoot<WindowProxy>
     {
         if let Some(window_proxy) = self.window_proxies.borrow().get(&browsing_context_id) {
             window_proxy.set_currently_active(&*window);
             return DomRoot::from_ref(window_proxy);
         }
-        let iframe = match parent_info {
-            Some((parent_id, FrameType::IFrame)) => self.documents.borrow().find_iframe(parent_id, browsing_context_id),
-            _ => None,
-        };
+        let iframe = parent_info.and_then(|parent_id| {
+            self.documents.borrow().find_iframe(parent_id, browsing_context_id)
+        });
         let parent = match (parent_info, iframe.as_ref()) {
             (_, Some(iframe)) => Some(window_from_node(&**iframe).window_proxy()),
-            (Some((parent_id, FrameType::IFrame)), _) => self.remote_window_proxy(window.upcast(),
-                                                                                  top_level_browsing_context_id,
-                                                                                  parent_id),
+            (Some(parent_id), _) => self.remote_window_proxy(window.upcast(),
+                                                              top_level_browsing_context_id,
+                                                              parent_id),
             _ => None,
         };
         let window_proxy = WindowProxy::new(&window,
                                             browsing_context_id,
                                             top_level_browsing_context_id,
                                             iframe.r().map(Castable::upcast),
                                             parent.r());
         self.window_proxies.borrow_mut().insert(browsing_context_id, Dom::from_ref(&*window_proxy));
@@ -2373,29 +2340,16 @@ impl ScriptThread {
                         self.script_sender.send((pipeline_id, message)).unwrap();
                     }
                     _ => {
                         // TODO: Calling preventDefault on a touchup event should prevent clicks.
                     }
                 }
             }
 
-            TouchpadPressureEvent(_point, pressure, phase, node_address) => {
-                let doc = match { self.documents.borrow().find_document(pipeline_id) } {
-                    Some(doc) => doc,
-                    None => return warn!("Message sent to closed pipeline {}.", pipeline_id),
-                };
-                doc.handle_touchpad_pressure_event(
-                    self.js_runtime.rt(),
-                    pressure,
-                    phase,
-                    node_address
-                );
-            }
-
             KeyEvent(ch, key, state, modifiers) => {
                 let document = match { self.documents.borrow().find_document(pipeline_id) } {
                     Some(document) => document,
                     None => return warn!("Message sent to closed pipeline {}.", pipeline_id),
                 };
                 document.dispatch_key_event(ch, key, state, modifiers);
             }
         }
--- a/servo/components/script_traits/lib.rs
+++ b/servo/components/script_traits/lib.rs
@@ -43,23 +43,22 @@ use canvas_traits::webgl::WebGLPipeline;
 use devtools_traits::{DevtoolScriptControlMsg, ScriptToDevtoolsControlMsg, WorkerId};
 use euclid::{Size2D, Length, Point2D, Vector2D, Rect, TypedScale, TypedSize2D};
 use gfx_traits::Epoch;
 use hyper::header::Headers;
 use hyper::method::Method;
 use ipc_channel::{Error as IpcError};
 use ipc_channel::ipc::{IpcReceiver, IpcSender};
 use libc::c_void;
-use msg::constellation_msg::{BrowsingContextId, TopLevelBrowsingContextId, FrameType, Key, KeyModifiers, KeyState};
+use msg::constellation_msg::{BrowsingContextId, TopLevelBrowsingContextId, Key, KeyModifiers, KeyState};
 use msg::constellation_msg::{PipelineId, PipelineNamespaceId, TraversalDirection};
 use net_traits::{FetchResponseMsg, ReferrerPolicy, ResourceThreads};
 use net_traits::image::base::Image;
 use net_traits::image::base::PixelFormat;
 use net_traits::image_cache::ImageCache;
-use net_traits::response::HttpsState;
 use net_traits::storage_thread::StorageType;
 use profile_traits::mem;
 use profile_traits::time as profile_time;
 use serde::{Deserialize, Deserializer, Serialize, Serializer};
 use servo_atoms::Atom;
 use servo_url::ImmutableOrigin;
 use servo_url::ServoUrl;
 use std::collections::HashMap;
@@ -181,17 +180,17 @@ impl LoadData {
     }
 }
 
 /// The initial data required to create a new layout attached to an existing script thread.
 #[derive(Deserialize, Serialize)]
 pub struct NewLayoutInfo {
     /// The ID of the parent pipeline and frame type, if any.
     /// If `None`, this is a root pipeline.
-    pub parent_info: Option<(PipelineId, FrameType)>,
+    pub parent_info: Option<PipelineId>,
     /// Id of the newly-created pipeline.
     pub new_pipeline_id: PipelineId,
     /// Id of the browsing context associated with this pipeline.
     pub browsing_context_id: BrowsingContextId,
     /// Id of the top-level browsing context associated with this pipeline.
     pub top_level_browsing_context_id: TopLevelBrowsingContextId,
     /// Network request data which will be initiated by the script thread.
     pub load_data: LoadData,
@@ -282,19 +281,16 @@ pub enum ConstellationControlMsg {
     /// Notifies script thread that frame visibility change is complete
     /// PipelineId is for the parent, BrowsingContextId is for the nested browsing context
     NotifyVisibilityChange(PipelineId, BrowsingContextId, bool),
     /// Notifies script thread that a url should be loaded in this iframe.
     /// PipelineId is for the parent, BrowsingContextId is for the nested browsing context
     Navigate(PipelineId, BrowsingContextId, LoadData, bool),
     /// Post a message to a given window.
     PostMessage(PipelineId, Option<ImmutableOrigin>, Vec<u8>),
-    /// Requests the script thread forward a mozbrowser event to a mozbrowser iframe it owns,
-    /// or to the window if no browsing context id is provided.
-    MozBrowserEvent(PipelineId, Option<TopLevelBrowsingContextId>, MozBrowserEvent),
     /// Updates the current pipeline ID of a given iframe.
     /// First PipelineId is for the parent, second is the new PipelineId for the frame.
     UpdatePipelineId(PipelineId, BrowsingContextId, PipelineId, UpdatePipelineIdReason),
     /// Set an iframe to be focused. Used when an element in an iframe gains focus.
     /// PipelineId is for the parent, BrowsingContextId is for the nested browsing context
     FocusIFrame(PipelineId, BrowsingContextId),
     /// Passes a webdriver command to the script thread for execution
     WebDriverScriptCommand(PipelineId, WebDriverScriptCommand),
@@ -341,17 +337,16 @@ impl fmt::Debug for ConstellationControl
             Viewport(..) => "Viewport",
             SetScrollState(..) => "SetScrollState",
             GetTitle(..) => "GetTitle",
             SetDocumentActivity(..) => "SetDocumentActivity",
             ChangeFrameVisibilityStatus(..) => "ChangeFrameVisibilityStatus",
             NotifyVisibilityChange(..) => "NotifyVisibilityChange",
             Navigate(..) => "Navigate",
             PostMessage(..) => "PostMessage",
-            MozBrowserEvent(..) => "MozBrowserEvent",
             UpdatePipelineId(..) => "UpdatePipelineId",
             FocusIFrame(..) => "FocusIFrame",
             WebDriverScriptCommand(..) => "WebDriverScriptCommand",
             TickAllAnimations(..) => "TickAllAnimations",
             TransitionEnd(..) => "TransitionEnd",
             WebFontLoaded(..) => "WebFontLoaded",
             DispatchIFrameLoadEvent { .. } => "DispatchIFrameLoadEvent",
             DispatchStorageEvent(..) => "DispatchStorageEvent",
@@ -440,33 +435,20 @@ pub enum CompositorEvent {
         Point2D<f32>,
         Option<UntrustedNodeAddress>,
         Option<Point2D<f32>>
     ),
     /// The mouse was moved over a point (or was moved out of the recognizable region).
     MouseMoveEvent(Option<Point2D<f32>>, Option<UntrustedNodeAddress>),
     /// A touch event was generated with a touch ID and location.
     TouchEvent(TouchEventType, TouchId, Point2D<f32>, Option<UntrustedNodeAddress>),
-    /// Touchpad pressure event
-    TouchpadPressureEvent(Point2D<f32>, f32, TouchpadPressurePhase, Option<UntrustedNodeAddress>),
     /// A key was pressed.
     KeyEvent(Option<char>, Key, KeyState, KeyModifiers),
 }
 
-/// Touchpad pressure phase for `TouchpadPressureEvent`.
-#[derive(Clone, Copy, Deserialize, MallocSizeOf, PartialEq, Serialize)]
-pub enum TouchpadPressurePhase {
-    /// Pressure before a regular click.
-    BeforeClick,
-    /// Pressure after a regular click.
-    AfterFirstClick,
-    /// Pressure after a "forceTouch" click
-    AfterSecondClick,
-}
-
 /// Requests a TimerEvent-Message be sent after the given duration.
 #[derive(Deserialize, Serialize)]
 pub struct TimerEventRequest(pub IpcSender<TimerEvent>, pub TimerSource, pub TimerEventId, pub MsDuration);
 
 /// Type of messages that can be sent to the timer scheduler.
 #[derive(Deserialize, Serialize)]
 pub enum TimerSchedulerMsg {
     /// Message to schedule a new timer event.
@@ -519,17 +501,17 @@ pub fn precise_time_ns() -> NsDuration {
 ///
 /// NB: *DO NOT* add any Senders or Receivers here! pcwalton will have to rewrite your code if you
 /// do! Use IPC senders and receivers instead.
 pub struct InitialScriptState {
     /// The ID of the pipeline with which this script thread is associated.
     pub id: PipelineId,
     /// The subpage ID of this pipeline to create in its pipeline parent.
     /// If `None`, this is the root.
-    pub parent_info: Option<(PipelineId, FrameType)>,
+    pub parent_info: Option<PipelineId>,
     /// The ID of the browsing context this script is part of.
     pub browsing_context_id: BrowsingContextId,
     /// The ID of the top-level browsing context this script is part of.
     pub top_level_browsing_context_id: TopLevelBrowsingContextId,
     /// A channel with which messages can be sent to us (the script thread).
     pub control_chan: IpcSender<ConstellationControlMsg>,
     /// A port on which messages sent by the constellation to script can be received.
     pub control_port: IpcReceiver<ConstellationControlMsg>,
@@ -587,24 +569,21 @@ pub enum IFrameSandboxState {
 /// Specifies the information required to load an iframe.
 #[derive(Deserialize, Serialize)]
 pub struct IFrameLoadInfo {
     /// Pipeline ID of the parent of this iframe
     pub parent_pipeline_id: PipelineId,
     /// The ID for this iframe's nested browsing context.
     pub browsing_context_id: BrowsingContextId,
     /// The ID for the top-level ancestor browsing context of this iframe's nested browsing context.
-    /// Note: this is the same as the browsing_context_id for mozbrowser iframes.
     pub top_level_browsing_context_id: TopLevelBrowsingContextId,
     /// The new pipeline ID that the iframe has generated.
     pub new_pipeline_id: PipelineId,
     ///  Whether this iframe should be considered private
     pub is_private: bool,
-    /// Whether this iframe is a mozbrowser iframe
-    pub frame_type: FrameType,
     /// Wether this load should replace the current entry (reload). If true, the current
     /// entry will be replaced instead of a new entry being added.
     pub replace: bool,
 }
 
 /// Specifies the information required to load a URL in an iframe.
 #[derive(Deserialize, Serialize)]
 pub struct IFrameLoadInfoWithData {
@@ -613,104 +592,16 @@ pub struct IFrameLoadInfoWithData {
     /// Load data containing the url to load
     pub load_data: Option<LoadData>,
     /// The old pipeline ID for this iframe, if a page was previously loaded.
     pub old_pipeline_id: Option<PipelineId>,
     /// Sandbox type of this iframe
     pub sandbox: IFrameSandboxState,
 }
 
-// https://developer.mozilla.org/en-US/docs/Web/API/Using_the_Browser_API#Events
-/// The events fired in a Browser API context (`<iframe mozbrowser>`)
-#[derive(Deserialize, Serialize)]
-pub enum MozBrowserEvent {
-    /// Sent when the scroll position within a browser `<iframe>` changes.
-    AsyncScroll,
-    /// Sent when window.close() is called within a browser `<iframe>`.
-    Close,
-    /// Sent when a browser `<iframe>` tries to open a context menu. This allows
-    /// handling `<menuitem>` element available within the browser `<iframe>`'s content.
-    ContextMenu,
-    /// Sent when an error occurred while trying to load content within a browser `<iframe>`.
-    /// Includes a human-readable description, and a machine-readable report.
-    Error(MozBrowserErrorType, String, String),
-    /// Sent when the favicon of a browser `<iframe>` changes.
-    IconChange(String, String, String),
-    /// Sent when the browser `<iframe>` has reached the server.
-    Connected,
-    /// Sent when the browser `<iframe>` has finished loading all its assets.
-    LoadEnd,
-    /// Sent when the browser `<iframe>` starts to load a new page.
-    LoadStart,
-    /// Sent when a browser `<iframe>`'s location changes.
-    LocationChange(String, bool, bool),
-    /// Sent when a new tab is opened within a browser `<iframe>` as a result of the user
-    /// issuing a command to open a link target in a new tab (for example ctrl/cmd + click.)
-    /// Includes the URL.
-    OpenTab(String),
-    /// Sent when a new window is opened within a browser `<iframe>`.
-    /// Includes the URL, target browsing context name, and features.
-    OpenWindow(String, Option<String>, Option<String>),
-    /// Sent when the SSL state changes within a browser `<iframe>`.
-    SecurityChange(HttpsState),
-    /// Sent when alert(), confirm(), or prompt() is called within a browser `<iframe>`.
-    ShowModalPrompt(String, String, String, String), // TODO(simartin): Handle unblock()
-    /// Sent when the document.title changes within a browser `<iframe>`.
-    TitleChange(String),
-    /// Sent when an HTTP authentification is requested.
-    UsernameAndPasswordRequired,
-    /// Sent when a link to a search engine is found.
-    OpenSearch,
-    /// Sent when visibility state changes.
-    VisibilityChange(bool),
-}
-
-impl MozBrowserEvent {
-    /// Get the name of the event as a `& str`
-    pub fn name(&self) -> &'static str {
-        match *self {
-            MozBrowserEvent::AsyncScroll => "mozbrowserasyncscroll",
-            MozBrowserEvent::Close => "mozbrowserclose",
-            MozBrowserEvent::Connected => "mozbrowserconnected",
-            MozBrowserEvent::ContextMenu => "mozbrowsercontextmenu",
-            MozBrowserEvent::Error(_, _, _) => "mozbrowsererror",
-            MozBrowserEvent::IconChange(_, _, _) => "mozbrowsericonchange",
-            MozBrowserEvent::LoadEnd => "mozbrowserloadend",
-            MozBrowserEvent::LoadStart => "mozbrowserloadstart",
-            MozBrowserEvent::LocationChange(_, _, _) => "mozbrowserlocationchange",
-            MozBrowserEvent::OpenTab(_) => "mozbrowseropentab",
-            MozBrowserEvent::OpenWindow(_, _, _) => "mozbrowseropenwindow",
-            MozBrowserEvent::SecurityChange(_) => "mozbrowsersecuritychange",
-            MozBrowserEvent::ShowModalPrompt(_, _, _, _) => "mozbrowsershowmodalprompt",
-            MozBrowserEvent::TitleChange(_) => "mozbrowsertitlechange",
-            MozBrowserEvent::UsernameAndPasswordRequired => "mozbrowserusernameandpasswordrequired",
-            MozBrowserEvent::OpenSearch => "mozbrowseropensearch",
-            MozBrowserEvent::VisibilityChange(_) => "mozbrowservisibilitychange",
-        }
-    }
-}
-
-// https://developer.mozilla.org/en-US/docs/Web/Events/mozbrowsererror
-/// The different types of Browser error events
-#[derive(Deserialize, Serialize)]
-pub enum MozBrowserErrorType {
-    // For the moment, we are just reporting panics, using the "fatal" type.
-    /// A fatal error
-    Fatal,
-}
-
-impl MozBrowserErrorType {
-    /// Get the name of the error type as a `& str`
-    pub fn name(&self) -> &'static str {
-        match *self {
-            MozBrowserErrorType::Fatal => "fatal",
-        }
-    }
-}
-
 /// Specifies whether the script or layout thread needs to be ticked for animation.
 #[derive(Deserialize, Serialize)]
 pub enum AnimationTickType {
     /// The script thread.
     Script,
     /// The layout thread.
     Layout,
 }
--- a/servo/components/script_traits/script_msg.rs
+++ b/servo/components/script_traits/script_msg.rs
@@ -4,25 +4,24 @@
 
 use AnimationState;
 use CompositorEvent;
 use DocumentState;
 use IFrameLoadInfo;
 use IFrameLoadInfoWithData;
 use LayoutControlMsg;
 use LoadData;
-use MozBrowserEvent;
 use WorkerGlobalScopeInit;
 use WorkerScriptLoadOrigin;
 use canvas_traits::canvas::CanvasMsg;
 use devtools_traits::{ScriptToDevtoolsControlMsg, WorkerId};
 use euclid::{Point2D, Size2D, TypedSize2D};
 use gfx_traits::Epoch;
 use ipc_channel::ipc::{IpcReceiver, IpcSender};
-use msg::constellation_msg::{BrowsingContextId, FrameType, PipelineId, TraversalDirection};
+use msg::constellation_msg::{BrowsingContextId, PipelineId, TraversalDirection};
 use msg::constellation_msg::{Key, KeyModifiers, KeyState};
 use net_traits::CoreResourceMsg;
 use net_traits::request::RequestInit;
 use net_traits::storage_thread::StorageType;
 use servo_url::ImmutableOrigin;
 use servo_url::ServoUrl;
 use style_traits::CSSPixel;
 use style_traits::cursor::CursorKind;
@@ -84,31 +83,29 @@ pub enum ScriptMsg {
     Focus,
     /// Forward an event that was sent to the parent window.
     ForwardEvent(PipelineId, CompositorEvent),
     /// Requests that the constellation retrieve the current contents of the clipboard
     GetClipboardContents(IpcSender<String>),
     /// Get the browsing context id for a given pipeline.
     GetBrowsingContextId(PipelineId, IpcSender<Option<BrowsingContextId>>),
     /// Get the parent info for a given pipeline.
-    GetParentInfo(PipelineId, IpcSender<Option<(PipelineId, FrameType)>>),
+    GetParentInfo(PipelineId, IpcSender<Option<PipelineId>>),
     /// <head> tag finished parsing
     HeadParsed,
     /// All pending loads are complete, and the `load` event for this pipeline
     /// has been dispatched.
     LoadComplete,
     /// A new load has been requested, with an option to replace the current entry once loaded
     /// instead of adding a new entry.
     LoadUrl(LoadData, bool),
     /// Abort loading after sending a LoadUrl message.
     AbortLoadUrl,
     /// Post a message to the currently active window of a given browsing context.
     PostMessage(BrowsingContextId, Option<ImmutableOrigin>, Vec<u8>),
-    /// Dispatch a mozbrowser event to the parent of a mozbrowser iframe.
-    MozBrowserEvent(PipelineId, MozBrowserEvent),
     /// HTMLIFrameElement Forward or Back traversal.
     TraverseHistory(TraversalDirection),
     /// Gets the length of the joint session history from the constellation.
     JointSessionHistoryLength(IpcSender<u32>),
     /// Favicon detected
     NewFavicon(ServoUrl),
     /// Status message to be displayed in the chrome, eg. a link URL on mouseover.
     NodeStatus(Option<String>),
--- a/servo/components/servo/lib.rs
+++ b/servo/components/servo/lib.rs
@@ -306,20 +306,16 @@ impl<Window> Servo<Window> where Window:
 
             WindowEvent::Navigation(top_level_browsing_context_id, direction) => {
                 let msg = ConstellationMsg::TraverseHistory(top_level_browsing_context_id, direction);
                 if let Err(e) = self.constellation_chan.send(msg) {
                     warn!("Sending navigation to constellation failed ({}).", e);
                 }
             }
 
-            WindowEvent::TouchpadPressure(cursor, pressure, stage) => {
-                self.compositor.on_touchpad_pressure_event(cursor, pressure, stage);
-            }
-
             WindowEvent::KeyEvent(ch, key, state, modifiers) => {
                 let msg = ConstellationMsg::KeyEvent(ch, key, state, modifiers);
                 if let Err(e) = self.constellation_chan.send(msg) {
                     warn!("Sending key event to constellation failed ({}).", e);
                 }
             }
 
             WindowEvent::Quit => {
@@ -456,16 +452,21 @@ impl<Window> Servo<Window> where Window:
                 },
 
                 (EmbedderMsg::LoadComplete(top_level_browsing_context), ShutdownState::NotShuttingDown) => {
                     // Inform the embedder that the load has finished.
                     //
                     // TODO(pcwalton): Specify which frame's load completed.
                     self.compositor.window.load_end(top_level_browsing_context);
                 },
+                (EmbedderMsg::Panic(top_level_browsing_context, reason, backtrace),
+                 ShutdownState::NotShuttingDown) => {
+                    self.compositor.window.handle_panic(top_level_browsing_context, reason, backtrace);
+                },
+
             }
         }
     }
 
     pub fn handle_events(&mut self, events: Vec<WindowEvent>) -> bool {
         if self.compositor.receive_messages() {
             self.receive_messages();
         }
--- a/servo/ports/servo/Cargo.toml
+++ b/servo/ports/servo/Cargo.toml
@@ -21,17 +21,16 @@ webdriver = ["libservo/webdriver"]
 energy-profiling = ["libservo/energy-profiling"]
 debugmozjs = ["libservo/debugmozjs"]
 googlevr = ["libservo/googlevr"]
 oculusvr = ["libservo/oculusvr"]
 unstable = ["libservo/unstable"]
 
 [dependencies]
 backtrace = "0.3"
-browserhtml = {git = "https://github.com/browserhtml/browserhtml", branch = "crate"}
 bitflags = "1.0"
 compositing = {path = "../../components/compositing"}
 euclid = "0.16"
 gleam = "0.4"
 libservo = {path = "../../components/servo"}
 log = "0.3.5"
 msg = {path = "../../components/msg"}
 net_traits = {path = "../../components/net_traits"}
--- a/servo/ports/servo/glutin_app/window.rs
+++ b/servo/ports/servo/glutin_app/window.rs
@@ -18,17 +18,17 @@ use glutin::ScanCode;
 use glutin::TouchPhase;
 #[cfg(target_os = "macos")]
 use glutin::os::macos::{ActivationPolicy, WindowBuilderExt};
 use msg::constellation_msg::{self, Key, TopLevelBrowsingContextId as BrowserId};
 use msg::constellation_msg::{KeyModifiers, KeyState, TraversalDirection};
 use net_traits::net_error_list::NetError;
 #[cfg(any(target_os = "linux", target_os = "macos"))]
 use osmesa_sys;
-use script_traits::{LoadData, TouchEventType, TouchpadPressurePhase};
+use script_traits::{LoadData, TouchEventType};
 use servo::ipc_channel::ipc::IpcSender;
 use servo_config::opts;
 use servo_config::prefs::PREFS;
 use servo_config::resource_files;
 use servo_geometry::DeviceIndependentPixel;
 use servo_url::ServoUrl;
 use std::cell::{Cell, RefCell};
 #[cfg(any(target_os = "linux", target_os = "macos"))]
@@ -513,22 +513,16 @@ impl Window {
             Event::Touch(touch) => {
                 use script_traits::TouchId;
 
                 let phase = glutin_phase_to_touch_event_type(touch.phase);
                 let id = TouchId(touch.id as i32);
                 let point = TypedPoint2D::new(touch.location.0 as f32, touch.location.1 as f32);
                 self.event_queue.borrow_mut().push(WindowEvent::Touch(phase, id, point));
             }
-            Event::TouchpadPressure(pressure, stage) => {
-                let m = self.mouse_pos.get();
-                let point = TypedPoint2D::new(m.x as f32, m.y as f32);
-                let phase = glutin_pressure_stage_to_touchpad_pressure_phase(stage);
-                self.event_queue.borrow_mut().push(WindowEvent::TouchpadPressure(point, pressure, phase));
-            }
             Event::Refresh => {
                 self.event_queue.borrow_mut().push(WindowEvent::Refresh);
             }
             Event::Closed => {
                 return true
             }
             _ => {}
         }
@@ -1355,37 +1349,31 @@ impl WindowMethods for Window {
         if let Err(e) = response_chan.send(true) {
             warn!("Failed to send allow_navigation() response: {}", e);
         };
     }
 
     fn supports_clipboard(&self) -> bool {
         true
     }
+
+    fn handle_panic(&self, _: BrowserId, _reason: String, _backtrace: Option<String>) {
+        // Nothing to do here yet. The crash has already been reported on the console.
+    }
 }
 
 fn glutin_phase_to_touch_event_type(phase: TouchPhase) -> TouchEventType {
     match phase {
         TouchPhase::Started => TouchEventType::Down,
         TouchPhase::Moved => TouchEventType::Move,
         TouchPhase::Ended => TouchEventType::Up,
         TouchPhase::Cancelled => TouchEventType::Cancel,
     }
 }
 
-fn glutin_pressure_stage_to_touchpad_pressure_phase(stage: i64) -> TouchpadPressurePhase {
-    if stage < 1 {
-        TouchpadPressurePhase::BeforeClick
-    } else if stage < 2 {
-        TouchpadPressurePhase::AfterFirstClick
-    } else {
-        TouchpadPressurePhase::AfterSecondClick
-    }
-}
-
 fn is_printable(key_code: VirtualKeyCode) -> bool {
     use glutin::VirtualKeyCode::*;
     match key_code {
         Escape |
         F1 |
         F2 |
         F3 |
         F4 |
--- a/servo/python/servo/command_base.py
+++ b/servo/python/servo/command_base.py
@@ -60,23 +60,16 @@ def find_dep_path_newest(package, bin_pa
             candidate_path = path.join(deps_path, c)
             if path.exists(path.join(candidate_path, "output")):
                 candidates.append(candidate_path)
     if candidates:
         return max(candidates, key=lambda c: path.getmtime(path.join(c, "output")))
     return None
 
 
-def get_browserhtml_path(binary_path):
-    browserhtml_path = find_dep_path_newest('browserhtml', binary_path)
-    if browserhtml_path:
-        return path.join(browserhtml_path, "out")
-    sys.exit("Could not find browserhtml package; perhaps you haven't built Servo.")
-
-
 def archive_deterministically(dir_to_archive, dest_archive, prepend_path=None):
     """Create a .tar.gz archive in a deterministic (reproducible) manner.
 
     See https://reproducible-builds.org/docs/archives/ for more details."""
 
     def reset(tarinfo):
         """Helper to reset owner/group and modification time for tar entries"""
         tarinfo.uid = tarinfo.gid = 0
--- a/servo/python/servo/package_commands.py
+++ b/servo/python/servo/package_commands.py
@@ -31,17 +31,16 @@ sys.path.append(path.join(path.dirname(_
 
 from servo.command_base import (
     archive_deterministically,
     BuildNotFound,
     cd,
     CommandBase,
     is_macosx,
     is_windows,
-    get_browserhtml_path,
 )
 from servo.util import delete
 
 
 PACKAGES = {
     'android': [
         'target/armv7-linux-androideabi/release/servo.apk',
     ],
@@ -223,21 +222,19 @@ class PackageCommands(CommandBase):
         elif is_macosx():
             print("Creating Servo.app")
             dir_to_dmg = path.join(target_dir, 'dmg')
             dir_to_app = path.join(dir_to_dmg, 'Servo.app')
             dir_to_resources = path.join(dir_to_app, 'Contents', 'Resources')
             if path.exists(dir_to_dmg):
                 print("Cleaning up from previous packaging")
                 delete(dir_to_dmg)
-            browserhtml_path = get_browserhtml_path(binary_path)
 
             print("Copying files")
             shutil.copytree(path.join(dir_to_root, 'resources'), dir_to_resources)
-            shutil.copytree(browserhtml_path, path.join(dir_to_resources, 'browserhtml'))
             shutil.copy2(path.join(dir_to_root, 'Info.plist'), path.join(dir_to_app, 'Contents', 'Info.plist'))
 
             content_dir = path.join(dir_to_app, 'Contents', 'MacOS')
             os.makedirs(content_dir)
             shutil.copy2(binary_path, content_dir)
 
             change_prefs(dir_to_resources, "macosx")
 
@@ -259,26 +256,16 @@ class PackageCommands(CommandBase):
             template_path = path.join(dir_to_resources, 'Credits.rtf.mako')
             credits_path = path.join(dir_to_resources, 'Credits.rtf')
             with open(template_path) as template_file:
                 template = mako.template.Template(template_file.read())
                 with open(credits_path, "w") as credits_file:
                     credits_file.write(template.render(version=version))
             delete(template_path)
 
-            print("Writing run-servo")
-            bhtml_path = path.join('${0%/*}', '..', 'Resources', 'browserhtml', 'index.html')
-            runservo = os.open(
-                path.join(content_dir, 'run-servo'),
-                os.O_WRONLY | os.O_CREAT,
-                int("0755", 8)
-            )
-            os.write(runservo, '#!/bin/bash\nexec ${0%/*}/servo ' + bhtml_path)
-            os.close(runservo)
-
             print("Creating dmg")
             os.symlink('/Applications', path.join(dir_to_dmg, 'Applications'))
             dmg_path = path.join(target_dir, "servo-tech-demo.dmg")
 
             if path.exists(dmg_path):
                 print("Deleting existing dmg")
                 os.remove(dmg_path)
 
@@ -318,24 +305,22 @@ class PackageCommands(CommandBase):
             delete(dir_to_brew)
             print("Packaged Servo into " + tar_path)
         elif is_windows():
             dir_to_msi = path.join(target_dir, 'msi')
             if path.exists(dir_to_msi):
                 print("Cleaning up from previous packaging")
                 delete(dir_to_msi)
             os.makedirs(dir_to_msi)
-            browserhtml_path = get_browserhtml_path(binary_path)
 
             print("Copying files")
             dir_to_temp = path.join(dir_to_msi, 'temp')
             dir_to_temp_servo = path.join(dir_to_temp, 'servo')
             dir_to_resources = path.join(dir_to_temp_servo, 'resources')
             shutil.copytree(path.join(dir_to_root, 'resources'), dir_to_resources)
-            shutil.copytree(browserhtml_path, path.join(dir_to_temp_servo, 'browserhtml'))
             shutil.copy(binary_path, dir_to_temp_servo)
             shutil.copy("{}.manifest".format(binary_path), dir_to_temp_servo)
             copy_windows_dependencies(target_dir, dir_to_temp_servo)
 
             change_prefs(dir_to_resources, "windows")
 
             # generate Servo.wxs
             import mako.template
@@ -367,26 +352,24 @@ class PackageCommands(CommandBase):
             print("Creating ZIP")
             shutil.make_archive(path.join(dir_to_msi, "Servo"), "zip", dir_to_temp)
             print("Packaged Servo into " + path.join(dir_to_msi, "Servo.zip"))
 
             print("Cleaning up")
             delete(dir_to_temp)
         else:
             dir_to_temp = path.join(target_dir, 'packaging-temp')
-            browserhtml_path = get_browserhtml_path(binary_path)
             if path.exists(dir_to_temp):
                 # TODO(aneeshusa): lock dir_to_temp to prevent simultaneous builds
                 print("Cleaning up from previous packaging")
                 delete(dir_to_temp)
 
             print("Copying files")
             dir_to_resources = path.join(dir_to_temp, 'resources')
             shutil.copytree(path.join(dir_to_root, 'resources'), dir_to_resources)
-            shutil.copytree(browserhtml_path, path.join(dir_to_temp, 'browserhtml'))
             shutil.copy(binary_path, dir_to_temp)
 
             change_prefs(dir_to_resources, "linux")
 
             print("Creating tarball")
             tar_path = path.join(target_dir, 'servo-tech-demo.tar.gz')
 
             archive_deterministically(dir_to_temp, tar_path, prepend_path='servo/')
--- a/servo/python/servo/post_build_commands.py
+++ b/servo/python/servo/post_build_commands.py
@@ -18,18 +18,17 @@ from mach.decorators import (
     CommandArgument,
     CommandProvider,
     Command,
 )
 
 from servo.command_base import (
     CommandBase,
     check_call, check_output, BIN_SUFFIX,
-    is_linux, is_windows, is_macosx, set_osmesa_env,
-    get_browserhtml_path,
+    is_linux, set_osmesa_env,
 )
 
 
 def read_file(filename, if_exists=False):
     if if_exists and not path.exists(filename):
         return None
     with open(filename) as f:
         return f.read()
@@ -48,28 +47,26 @@ class PostBuildCommands(CommandBase):
                      help='Run on an Android device through `adb shell`')
     @CommandArgument('--debug', action='store_true',
                      help='Enable the debugger. Not specifying a '
                           '--debugger option will result in the default '
                           'debugger being used. The following arguments '
                           'have no effect without this.')
     @CommandArgument('--debugger', default=None, type=str,
                      help='Name of debugger to use.')
-    @CommandArgument('--browserhtml', '-b', action='store_true',
-                     help='Launch with Browser.html')
     @CommandArgument('--headless', '-z', action='store_true',
                      help='Launch in headless mode')
     @CommandArgument('--software', '-s', action='store_true',
                      help='Launch with software rendering')
     @CommandArgument('--bin', default=None,
                      help='Launch with specific binary')
     @CommandArgument(
         'params', nargs='...',
         help="Command-line arguments to be passed through to Servo")
-    def run(self, params, release=False, dev=False, android=None, debug=False, debugger=None, browserhtml=False,
+    def run(self, params, release=False, dev=False, android=None, debug=False, debugger=None,
             headless=False, software=False, bin=None):
         env = self.build_env()
         env["RUST_BACKTRACE"] = "1"
 
         # Make --debugger imply --debug
         if debugger:
             debug = True
 
@@ -95,30 +92,16 @@ class PostBuildCommands(CommandBase):
                 "exit"
             ]
             shell = subprocess.Popen(["adb", "shell"], stdin=subprocess.PIPE)
             shell.communicate("\n".join(script) + "\n")
             return shell.wait()
 
         args = [bin or self.get_binary_path(release, dev)]
 
-        if browserhtml:
-            browserhtml_path = get_browserhtml_path(args[0])
-            if is_macosx():
-                # Enable borderless on OSX
-                args = args + ['-b']
-            elif is_windows():
-                # Convert to a relative path to avoid mingw -> Windows path conversions
-                browserhtml_path = path.relpath(browserhtml_path, os.getcwd())
-
-            args = args + ['--pref', 'dom.mozbrowser.enabled',
-                           '--pref', 'dom.forcetouch.enabled',
-                           '--pref', 'shell.builtin-key-shortcuts.enabled=false',
-                           path.join(browserhtml_path, 'index.html')]
-
         if headless:
             set_osmesa_env(args[0], env)
             args.append('-z')
 
         if software:
             if not is_linux():
                 print("Software rendering is only supported on Linux at the moment.")
                 return
--- a/servo/resources/package-prefs.json
+++ b/servo/resources/package-prefs.json
@@ -1,7 +1,3 @@
 {
-  "dom.forcetouch.enabled": true,
-  "dom.mozbrowser.enabled": true,
-  "shell.builtin-key-shortcuts.enabled": false,
-  "os:windows,os:linux;shell.homepage": "browserhtml/index.html",
-  "os:macosx;shell.native-titlebar.enabled": false
+  "_comment": "this file is used to add some specific preferences to the Servo package (nightly builds)"
 }
--- a/servo/resources/prefs.json
+++ b/servo/resources/prefs.json
@@ -3,17 +3,16 @@
   "dom.bluetooth.testing.enabled": false,
   "dom.canvas-text.enabled": false,
   "dom.compositionevent.enabled": false,
   "dom.customelements.enabled": true,
   "dom.forcetouch.enabled": false,
   "dom.gamepad.enabled": false,
   "dom.microdata.testing.enabled": true,
   "dom.mouseevent.which.enabled": false,
-  "dom.mozbrowser.enabled": false,
   "dom.mutation_observer.enabled": false,
   "dom.permissions.enabled": false,
   "dom.permissions.testing.allowed_in_nonsecure_contexts": false,
   "dom.serviceworker.timeout_seconds": 60,
   "dom.servoparser.async_html_tokenizer.enabled": false,
   "dom.testable_crash.enabled": false,
   "dom.testbinding.enabled": false,
   "dom.webgl.dom_to_texture.enabled": false,
--- a/servo/servo-tidy.toml
+++ b/servo/servo-tidy.toml
@@ -49,17 +49,16 @@ files = [
   "./components/style/gecko/non_ts_pseudo_class_list.rs",
   # Generated and upstream code combined with our own. Could use cleanup
   "./components/style/gecko/generated/bindings.rs",
   "./components/style/gecko/generated/pseudo_element_definition.rs",
   "./components/style/gecko/generated/structs.rs",
   "./components/style/gecko/generated/atom_macro.rs",
   "./resources/hsts_preload.json",
   "./tests/wpt/metadata/MANIFEST.json",
-  "./components/script/dom/webidls/ForceTouchEvent.webidl",
   "./support/android/openssl.sh",
   # Upstream code from Khronos/WebGL uses tabs for indentation
   "./tests/wpt/mozilla/tests/webgl",
   # Ignore those files since the issues reported are on purpose
   "./tests/html/bad-line-ends.html",
   "./tests/wpt/mozilla/tests/css/fonts",
   "./tests/wpt/mozilla/tests/css/pre_with_tab.html",
   "./tests/wpt/mozilla/tests/mozilla/textarea_placeholder.html",
--- a/servo/support/windows/Servo.wxs.mako
+++ b/servo/support/windows/Servo.wxs.mako
@@ -39,17 +39,16 @@
                           Icon="Servo.ico"
                           IconIndex="0"
                           Advertise="yes"/>
               </File>
               ${include_dependencies()}
             </Component>
 
             ${include_directory(resources_path, "resources")}
-            ${include_directory(path.join(dir_to_temp, "browserhtml"), "browserhtml")}
           </Directory>
         </Directory>
       </Directory>
 
       <Directory Id="ProgramMenuFolder" Name="Programs">
         <Directory Id="ProgramMenuDir" Name="Servo Tech Demo">
           <Component Id="ProgramMenuDir" Guid="e04737ce-16eb-4977-9b4c-ed2db8a5a77d">
             <RemoveFolder Id="ProgramMenuDir" On="both"/>