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

Unified Diff: Source/WebCore/dom/UserGestureIndicator.cpp

Issue 12886025: Merge 145481 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1410/
Patch Set: Created 7 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
« no previous file with comments | « Source/WebCore/dom/UserGestureIndicator.h ('k') | Source/WebCore/page/EventHandler.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebCore/dom/UserGestureIndicator.cpp
===================================================================
--- Source/WebCore/dom/UserGestureIndicator.cpp (revision 146136)
+++ Source/WebCore/dom/UserGestureIndicator.cpp (working copy)
@@ -59,7 +59,7 @@
static bool isDefinite(ProcessingUserGestureState state)
{
- return state == DefinitelyProcessingNewUserGesture || state == DefinitelyNotProcessingUserGesture;
+ return state == DefinitelyProcessingNewUserGesture || state == DefinitelyProcessingUserGesture || state == DefinitelyNotProcessingUserGesture;
}
ProcessingUserGestureState UserGestureIndicator::s_state = DefinitelyNotProcessingUserGesture;
@@ -80,6 +80,8 @@
if (state == DefinitelyProcessingNewUserGesture)
static_cast<GestureToken*>(m_token.get())->addGesture();
+ else if (state == DefinitelyProcessingUserGesture && s_topmostIndicator == this)
+ static_cast<GestureToken*>(m_token.get())->addGesture();
ASSERT(isDefinite(s_state));
}
@@ -95,7 +97,7 @@
static_cast<GestureToken*>(m_token.get())->addGesture();
static_cast<GestureToken*>(token.get())->consumeGesture();
}
- s_state = DefinitelyProcessingNewUserGesture;
+ s_state = DefinitelyProcessingUserGesture;
}
ASSERT(isDefinite(s_state));
@@ -111,7 +113,7 @@
bool UserGestureIndicator::processingUserGesture()
{
- return s_topmostIndicator && static_cast<GestureToken*>(s_topmostIndicator->currentToken())->hasGestures() && s_state == DefinitelyProcessingNewUserGesture;
+ return s_topmostIndicator && static_cast<GestureToken*>(s_topmostIndicator->currentToken())->hasGestures() && (s_state == DefinitelyProcessingNewUserGesture || s_state == DefinitelyProcessingUserGesture);
}
bool UserGestureIndicator::consumeUserGesture()
« no previous file with comments | « Source/WebCore/dom/UserGestureIndicator.h ('k') | Source/WebCore/page/EventHandler.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698