diff options
author | Ms2ger <ms2ger@gmail.com> | 2015-01-02 12:45:28 +0100 |
---|---|---|
committer | Josh Matthews <josh@joshmatthews.net> | 2015-01-08 09:58:46 -0500 |
commit | 16c7060bc8ff91527ae97f8a3feee5706747b9c5 (patch) | |
tree | 0cc29f2cc50c729d3a8f9521a22991fad67b9afd /components/util/geometry.rs | |
parent | cf616b90a236f88058dbad74b568b4d4379d2829 (diff) | |
download | servo-16c7060bc8ff91527ae97f8a3feee5706747b9c5.tar.gz servo-16c7060bc8ff91527ae97f8a3feee5706747b9c5.zip |
Update rustc to revision 2cfb5acb5a2751c759627377e602bac4f88f2d19.
Diffstat (limited to 'components/util/geometry.rs')
-rw-r--r-- | components/util/geometry.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/components/util/geometry.rs b/components/util/geometry.rs index 1191edba02a..5c3ee808b43 100644 --- a/components/util/geometry.rs +++ b/components/util/geometry.rs @@ -29,7 +29,7 @@ use std::fmt; /// /// The ratio between ScreenPx and DevicePixel for a given display be found by calling /// `servo::windowing::WindowMethods::hidpi_factor`. -#[deriving(Show)] +#[deriving(Show, Copy)] pub enum ScreenPx {} /// One CSS "px" in the coordinate system of the "initial viewport": @@ -41,7 +41,7 @@ pub enum ScreenPx {} /// /// At the default zoom level of 100%, one PagePx is equal to one ScreenPx. However, if the /// document is zoomed in or out then this scale may be larger or smaller. -#[deriving(Encodable, Show)] +#[deriving(Encodable, Show, Copy)] pub enum ViewportPx {} /// One CSS "px" in the root coordinate system for the content document. @@ -50,7 +50,7 @@ pub enum ViewportPx {} /// This is the mobile-style "pinch zoom" that enlarges content without reflowing it. When the /// viewport zoom is not equal to 1.0, then the layout viewport is no longer the same physical size /// as the viewable area. -#[deriving(Encodable, Show)] +#[deriving(Encodable, Show, Copy)] pub enum PagePx {} // In summary, the hierarchy of pixel units and the factors to convert from one to the next: @@ -65,7 +65,7 @@ pub enum PagePx {} // See https://bugzilla.mozilla.org/show_bug.cgi?id=177805 for more info. // // FIXME: Implement Au using Length and ScaleFactor instead of a custom type. -#[deriving(Clone, Hash, PartialEq, PartialOrd, Eq, Ord, Zero)] +#[deriving(Clone, Copy, Hash, PartialEq, PartialOrd, Eq, Ord)] pub struct Au(pub i32); impl Default for Au { |