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

Unified Diff: content/common/input/synthetic_pointer_action_params.h

Issue 2178153002: Prepare SyntheticPointerAction to handle mouse actions (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add comment Created 4 years, 4 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 | « content/browser/renderer_host/input/synthetic_pointer_action_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/input/synthetic_pointer_action_params.h
diff --git a/content/common/input/synthetic_pointer_action_params.h b/content/common/input/synthetic_pointer_action_params.h
index 641787c379ebdecf6e2432eba8e9ad6171ac9183..4e51f036b7352174c7fa2573d0d9b0cd090da414 100644
--- a/content/common/input/synthetic_pointer_action_params.h
+++ b/content/common/input/synthetic_pointer_action_params.h
@@ -51,6 +51,8 @@ struct CONTENT_EXPORT SyntheticPointerActionParams
void set_index(int index) {
DCHECK(pointer_action_type_ != PointerActionType::PROCESS &&
pointer_action_type_ != PointerActionType::FINISH);
+ // For all mouse pointer actions, the index should always be 0.
+ DCHECK(gesture_source_type != MOUSE_INPUT || index == 0);
index_ = index;
}
@@ -65,6 +67,7 @@ struct CONTENT_EXPORT SyntheticPointerActionParams
int index() const {
DCHECK(pointer_action_type_ != PointerActionType::PROCESS &&
pointer_action_type_ != PointerActionType::FINISH);
+ DCHECK(gesture_source_type != MOUSE_INPUT || index_ == 0);
return index_;
}
« no previous file with comments | « content/browser/renderer_host/input/synthetic_pointer_action_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698