diff options
author | Nikhil Shagrithaya <nikhilshagri@gmail.com> | 2016-06-30 16:02:57 +0530 |
---|---|---|
committer | Nikhil Shagrithaya <nikhilshagri@gmail.com> | 2016-06-30 16:09:01 +0530 |
commit | c7fd89a593bfd9b7d679a6fe5cf819f30d3959c9 (patch) | |
tree | 71b05f94e4565b2d3e9ebaa62da957f09d25f62e | |
parent | 26d2ee635589776a08e5671b6b6d673d165a5dc6 (diff) | |
download | servo-c7fd89a593bfd9b7d679a6fe5cf819f30d3959c9.tar.gz servo-c7fd89a593bfd9b7d679a6fe5cf819f30d3959c9.zip |
Creates KeyModifiers value using empty() instead of from_bits()
-rw-r--r-- | ports/glutin/window.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ports/glutin/window.rs b/ports/glutin/window.rs index 235afd4733c..e553ae0d188 100644 --- a/ports/glutin/window.rs +++ b/ports/glutin/window.rs @@ -576,7 +576,7 @@ impl Window { } fn glutin_mods_to_script_mods(modifiers: KeyModifiers) -> constellation_msg::KeyModifiers { - let mut result = constellation_msg::KeyModifiers::from_bits(0).expect("infallible"); + let mut result = constellation_msg::KeyModifiers::empty(); if modifiers.intersects(LEFT_SHIFT | RIGHT_SHIFT) { result.insert(SHIFT); } |