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

Unified Diff: chrome/browser/autocomplete/autocomplete_input.cc

Issue 131783012: Fix the handling of user gestures for external protocol handler dialogs. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: kalman comment Created 6 years, 9 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/autocomplete/autocomplete_input.cc
diff --git a/chrome/browser/autocomplete/autocomplete_input.cc b/chrome/browser/autocomplete/autocomplete_input.cc
index ea4285172a6a3c21fd963991f877554d079d22ff..770fe09f5ff925551fe4ea8582427d225c1c6a43 100644
--- a/chrome/browser/autocomplete/autocomplete_input.cc
+++ b/chrome/browser/autocomplete/autocomplete_input.cc
@@ -198,6 +198,9 @@ AutocompleteInput::Type AutocompleteInput::Parse(
// handlable schemes (e.g. "javascript") may be treated as "blocked" by the
// external protocol handler because we don't want pages to open them, but
// users still can.
+ // External protocol handler checks for the existence of a user gesture.
+ // Fake one so that we don't always get a BLOCK result.
Peter Kasting 2014/03/28 22:56:37 Nit: How about this comment, appended at the end o
meacer 2014/03/28 23:13:57 Done.
+ ExternalProtocolHandler::ScopedUserGesture skip_user_gesture_check;
ExternalProtocolHandler::BlockState block_state =
ExternalProtocolHandler::GetBlockState(
base::UTF16ToUTF8(parsed_scheme));

Powered by Google App Engine
This is Rietveld 408576698