servo: Merge #6011 - compositing: Fix scrolling timeout. There are 1,000,000 nanoseconds in a millisecond (from pcwalton:ns_to_ms); r=jdm

r? @jdm (or whoever)

Source-Repo: https://github.com/servo/servo
Source-Revision: 885068207f05b81bcf6f9fc14184a0b4d44eca10
This commit is contained in:
Patrick Walton 2015-05-11 16:53:32 -05:00
parent 7e998ce40e
commit 54c9da9180

View File

@ -60,7 +60,7 @@ impl ScrollingTimer {
Ok(ToScrollingTimerMsg::ScrollEventProcessedMsg(timestamp)) => {
let target = timestamp as i64 + TIMEOUT;
let delta_ns = target - (time::precise_time_ns() as i64);
sleep_ms((delta_ns / 1000) as u32);
sleep_ms((delta_ns / 1000000) as u32);
self.compositor_proxy.send(Msg::ScrollTimeout(timestamp));
}
Ok(ToScrollingTimerMsg::ExitMsg) | Err(_) => break,