Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(70)

Unified Diff: chrome/browser/renderer_host/chrome_render_widget_host_view_mac_history_swiper.mm

Issue 2227803003: Plumb phase/momentum for WheelEvent. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix Non-Mac compile. Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/renderer_host/chrome_render_widget_host_view_mac_history_swiper.mm
diff --git a/chrome/browser/renderer_host/chrome_render_widget_host_view_mac_history_swiper.mm b/chrome/browser/renderer_host/chrome_render_widget_host_view_mac_history_swiper.mm
index 3ec51eba7e70fdc8f2460e08407307e5cd6f6c53..ba517082270bd026e11bd2dc17aa2861d0567956 100644
--- a/chrome/browser/renderer_host/chrome_render_widget_host_view_mac_history_swiper.mm
+++ b/chrome/browser/renderer_host/chrome_render_widget_host_view_mac_history_swiper.mm
@@ -142,46 +142,6 @@ BOOL forceMagicMouse = NO;
}
}
-- (BOOL)canRubberbandLeft:(NSView*)view {
- Browser* browser = chrome::FindBrowserWithWindow([view window]);
- // If history swiping isn't possible, allow rubberbanding.
- if (!browser)
- return true;
-
- // TODO(erikchen): Update this comment after determining whether this
- // NULL-check fixes the crash.
- // This NULL check likely prevents a crash. http://crbug.com/418761
- if (!browser->tab_strip_model()->GetActiveWebContents())
- return true;
-
- if (!chrome::CanGoBack(browser))
- return true;
- // History swiping is possible. By default, disallow rubberbanding. If the
- // user has both started, and then cancelled history swiping for this
- // gesture, allow rubberbanding.
- return receivingTouches_ && recognitionState_ == history_swiper::kCancelled;
-}
-
-- (BOOL)canRubberbandRight:(NSView*)view {
- Browser* browser = chrome::FindBrowserWithWindow([view window]);
- // If history swiping isn't possible, allow rubberbanding.
- if (!browser)
- return true;
-
- // TODO(erikchen): Update this comment after determining whether this
- // NULL-check fixes the crash.
- // This NULL check likely prevents a crash. http://crbug.com/418761
- if (!browser->tab_strip_model()->GetActiveWebContents())
- return true;
-
- if (!chrome::CanGoForward(browser))
- return true;
- // History swiping is possible. By default, disallow rubberbanding. If the
- // user has both started, and then cancelled history swiping for this
- // gesture, allow rubberbanding.
- return receivingTouches_ && recognitionState_ == history_swiper::kCancelled;
-}
-
- (void)beginGestureWithEvent:(NSEvent*)event {
inGesture_ = YES;

Powered by Google App Engine
This is Rietveld 408576698