Index: ios/chrome/browser/ui/omnibox/omnibox_popup_material_view_controller.mm |
diff --git a/ios/chrome/browser/ui/omnibox/omnibox_popup_material_view_controller.mm b/ios/chrome/browser/ui/omnibox/omnibox_popup_material_view_controller.mm |
index 1493aa7d09d04cbc5e3acf0a93cc67ec603b3f07..f6da302cf26962e5c8faca8023fc10e73d74d899 100644 |
--- a/ios/chrome/browser/ui/omnibox/omnibox_popup_material_view_controller.mm |
+++ b/ios/chrome/browser/ui/omnibox/omnibox_popup_material_view_controller.mm |
@@ -656,11 +656,18 @@ initWithPopupView:(OmniboxPopupViewIOS*)view |
#pragma mark UIScrollViewDelegate |
- (void)scrollViewDidScroll:(UIScrollView*)scrollView { |
- // Setting the top inset of the scrollView to |kTopAndBottomPadding| causes a |
- // one time scrollViewDidScroll to |-kTopAndBottomPadding|. It's easier to |
- // just ignore this one scroll tick. |
- if (scrollView.contentOffset.y == 0 - kTopAndBottomPadding) |
- return; |
+ // TODO(crbug.com/733650): Default to the dragging check once it's been tested |
+ // on trunk. |
+ if (base::ios::IsRunningOnIOS11OrLater()) { |
+ if (!scrollView.dragging) |
+ return; |
+ } else { |
+ // Setting the top inset of the scrollView to |kTopAndBottomPadding| causes |
+ // a one time scrollViewDidScroll to |-kTopAndBottomPadding|. It's easier |
+ // to just ignore this one scroll tick. |
+ if (scrollView.contentOffset.y == 0 - kTopAndBottomPadding) |
+ return; |
+ } |
_popupView->DidScroll(); |
for (OmniboxPopupMaterialRow* row in _rows) { |