summaryrefslogtreecommitdiff
path: root/chromium/chrome/browser/resources/history/history.js
diff options
context:
space:
mode:
Diffstat (limited to 'chromium/chrome/browser/resources/history/history.js')
-rw-r--r--chromium/chrome/browser/resources/history/history.js10
1 files changed, 10 insertions, 0 deletions
diff --git a/chromium/chrome/browser/resources/history/history.js b/chromium/chrome/browser/resources/history/history.js
index 40a336123f9..3ea486d1f9a 100644
--- a/chromium/chrome/browser/resources/history/history.js
+++ b/chromium/chrome/browser/resources/history/history.js
@@ -1966,6 +1966,16 @@ function load() {
window.addEventListener(
'resize', historyView.updateClearBrowsingDataButton_);
+<if expr="is_ios">
+ // Trigger window resize event when search field is focused to force update
+ // of the clear browsing button, which should disappear when search field
+ // is active. The window is not resized when the virtual keyboard is shown
+ // on iOS.
+ searchField.addEventListener('focus', function() {
+ cr.dispatchSimpleEvent(window, 'resize');
+ });
+</if> /* is_ios */
+
// When the search field loses focus, add a delay before updating the
// visibility, otherwise the button will flash on the screen before the
// keyboard animates away.