Added support for navigating by a delta

This commit is contained in:
Connor Brewster 2016-06-04 15:22:18 -06:00
parent 80a58cadc5
commit c0ea1f16a8
5 changed files with 45 additions and 29 deletions

View file

@ -1803,8 +1803,8 @@ impl<Window: WindowMethods> IOCompositor<Window> {
fn on_navigation_window_event(&self, direction: WindowNavigateMsg) {
let direction = match direction {
windowing::WindowNavigateMsg::Forward => NavigationDirection::Forward,
windowing::WindowNavigateMsg::Back => NavigationDirection::Back,
windowing::WindowNavigateMsg::Forward => NavigationDirection::Forward(1),
windowing::WindowNavigateMsg::Back => NavigationDirection::Back(1),
};
let msg = ConstellationMsg::Navigate(None, direction);
if let Err(e) = self.constellation_chan.send(msg) {