diff options
author | James Gilbertson <james.gilbertson@luniv.ca> | 2015-03-24 23:46:47 -0600 |
---|---|---|
committer | James Gilbertson <james.gilbertson@luniv.ca> | 2015-05-06 00:34:33 -0600 |
commit | 138596e86136fdea14459c2c440e55593b67b626 (patch) | |
tree | 3be54ee8f5be8d17d6cfdfb1258c290f336f0b8a /components/msg | |
parent | 8977316d3ef99aab41873b0e30aa7d76b7bcd3d5 (diff) | |
download | servo-138596e86136fdea14459c2c440e55593b67b626.tar.gz servo-138596e86136fdea14459c2c440e55593b67b626.zip |
Constrain the viewport & zoom when reflowing
Diffstat (limited to 'components/msg')
-rw-r--r-- | components/msg/constellation_msg.rs | 5 | ||||
-rw-r--r-- | components/msg/lib.rs | 1 |
2 files changed, 5 insertions, 1 deletions
diff --git a/components/msg/constellation_msg.rs b/components/msg/constellation_msg.rs index 40ddb0161dd..d6a543f9b1c 100644 --- a/components/msg/constellation_msg.rs +++ b/components/msg/constellation_msg.rs @@ -14,6 +14,7 @@ use layers::geometry::DevicePixel; use util::cursor::Cursor; use util::geometry::{PagePx, ViewportPx}; use std::sync::mpsc::{channel, Sender, Receiver}; +use style::viewport::ViewportConstraints; use webdriver_traits::WebDriverScriptCommand; use url::Url; @@ -233,7 +234,9 @@ pub enum Msg { /// Requests that the constellation retrieve the current contents of the clipboard GetClipboardContents(Sender<String>), // Dispatch a webdriver command - WebDriverCommand(PipelineId, WebDriverScriptCommand) + WebDriverCommand(PipelineId, WebDriverScriptCommand), + /// Notifies the constellation that the viewport has been constrained in some manner + ViewportConstrained(PipelineId, ViewportConstraints), } // https://developer.mozilla.org/en-US/docs/Web/API/Using_the_Browser_API#Events diff --git a/components/msg/lib.rs b/components/msg/lib.rs index fc125583e95..558ccf55a96 100644 --- a/components/msg/lib.rs +++ b/components/msg/lib.rs @@ -9,6 +9,7 @@ extern crate hyper; extern crate layers; extern crate util; extern crate url; +extern crate style; extern crate webdriver_traits; #[cfg(target_os="macos")] |