summaryrefslogtreecommitdiffstats
path: root/src/core/web_contents_delegate_qt.cpp
diff options
context:
space:
mode:
authorKirill Burtsev <kirill.burtsev@qt.io>2019-07-15 13:03:14 +0200
committerKirill Burtsev <kirill.burtsev@qt.io>2019-07-16 22:47:33 +0200
commitb4589db4c7cb10cb55b38bab00d80eb1290312b1 (patch)
tree9c733e9052a946ef90ffc8fa7cff6d86d6d87c36 /src/core/web_contents_delegate_qt.cpp
parent73daf5b669c943d3c7a765533c5b5d61c380a576 (diff)
Reset findText reply id on StopFinding to prevent callback later
Not updating lastReceivedFindReply caused next findText call after StopFinding to trigger redundant callback call on checking stale query. Fixes: QTBUG-77029 Change-Id: Iad4b71364ecb3ec3db3096b739e77620d12731f9 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
Diffstat (limited to 'src/core/web_contents_delegate_qt.cpp')
-rw-r--r--src/core/web_contents_delegate_qt.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/web_contents_delegate_qt.cpp b/src/core/web_contents_delegate_qt.cpp
index 83f68b68d..20de0546f 100644
--- a/src/core/web_contents_delegate_qt.cpp
+++ b/src/core/web_contents_delegate_qt.cpp
@@ -510,7 +510,7 @@ void WebContentsDelegateQt::FindReply(content::WebContents *source, int request_
Q_UNUSED(source)
Q_UNUSED(selection_rect)
Q_UNUSED(active_match_ordinal)
- if (final_update) {
+ if (final_update && request_id > m_lastReceivedFindReply) {
m_lastReceivedFindReply = request_id;
m_viewClient->didFindText(request_id, number_of_matches);
}