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

Side by Side Diff: chrome/browser/external_protocol/external_protocol_observer.cc

Issue 1748553002: Replace MouseWheel events with GestureScrollBegin in WebContentsObserver::DidGetUserInteraction (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@remove-didgetusergesture
Patch Set: Created 4 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/external_protocol/external_protocol_observer.h" 5 #include "chrome/browser/external_protocol/external_protocol_observer.h"
6 6
7 #include "chrome/browser/external_protocol/external_protocol_handler.h" 7 #include "chrome/browser/external_protocol/external_protocol_handler.h"
8 8
9 using content::WebContents; 9 using content::WebContents;
10 10
11 DEFINE_WEB_CONTENTS_USER_DATA_KEY(ExternalProtocolObserver); 11 DEFINE_WEB_CONTENTS_USER_DATA_KEY(ExternalProtocolObserver);
12 12
13 ExternalProtocolObserver::ExternalProtocolObserver(WebContents* web_contents) 13 ExternalProtocolObserver::ExternalProtocolObserver(WebContents* web_contents)
14 : content::WebContentsObserver(web_contents) { 14 : content::WebContentsObserver(web_contents) {
15 } 15 }
16 16
17 ExternalProtocolObserver::~ExternalProtocolObserver() { 17 ExternalProtocolObserver::~ExternalProtocolObserver() {
18 } 18 }
19 19
20 void ExternalProtocolObserver::DidGetUserInteraction( 20 void ExternalProtocolObserver::DidGetUserInteraction(
21 const blink::WebInputEvent::Type type) { 21 const blink::WebInputEvent::Type type) {
22 // Ignore scroll events for allowing external protocol launch. 22 // Ignore scroll events for allowing external protocol launch.
23 if (type != blink::WebInputEvent::MouseWheel) 23 if (type != blink::WebInputEvent::GestureScrollBegin)
tdresser 2016/02/29 14:14:12 This also involves a behavior change for touch, do
dominickn 2016/02/29 22:52:02 See comment for the download request limiter.
24 ExternalProtocolHandler::PermitLaunchUrl(); 24 ExternalProtocolHandler::PermitLaunchUrl();
25 } 25 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698