Commit 02257c75 authored by Stepan Khapugin's avatar Stepan Khapugin Committed by Commit Bot

[iOS] Fix the bug with suggestion scrolling.

Fixes a bug that would close the popup when the suggestions are scrolled
up or down.

scroll the suggestion list. The keyboard should get dismissed on iPhone,
but the suggestion list should stay on screen until "cancel" is pressed.

Bug: 1039228
Test: On any page (and NTP), focus the omnibox and type something. Now
Change-Id: Ie174223e2b963a14eea9fb31ea8ecd8243bbee3b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2081415
Commit-Queue: Stepan Khapugin <stkhapugin@chromium.org>
Auto-Submit: Stepan Khapugin <stkhapugin@chromium.org>
Reviewed-by: default avatarRobbie Gibson <rkgibson@google.com>
Cr-Commit-Position: refs/heads/master@{#746030}
parent 815ad72c
......@@ -139,6 +139,7 @@
- (void)endEditing {
[self.textField resignFirstResponder];
_editView->EndEditing();
}
- (void)insertTextToOmnibox:(NSString*)text {
......
......@@ -221,15 +221,13 @@ const CGFloat kClearButtonSize = 28.0f;
return YES;
}
// When editing, forward the message on to |_textChangeDelegate|.
// Record the metrics as needed.
- (void)textFieldDidEndEditing:(UITextField*)textField
reason:(UITextFieldDidEndEditingReason)reason {
if (!self.omniboxInteractedWhileFocused) {
RecordAction(
UserMetricsAction("Mobile_FocusedDefocusedOmnibox_WithNoAction"));
}
DCHECK(_textChangeDelegate);
_textChangeDelegate->EndEditing();
}
- (BOOL)textFieldShouldClear:(UITextField*)textField {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment