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

Unified Diff: ui/events/blink/web_input_event_traits.cc

Issue 2782893002: WebMouseEvent coordinates are now fractional & private (Closed)
Patch Set: Fixed compile failures. Created 3 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: ui/events/blink/web_input_event_traits.cc
diff --git a/ui/events/blink/web_input_event_traits.cc b/ui/events/blink/web_input_event_traits.cc
index 5a76a3334c8075bb4afcb340e4879c50ae58edf5..38a671d59fae68c24acdb0f41d7351b723a3f65e 100644
--- a/ui/events/blink/web_input_event_traits.cc
+++ b/ui/events/blink/web_input_event_traits.cc
@@ -37,10 +37,11 @@ void ApppendEventDetails(const WebKeyboardEvent& event, std::string* result) {
void ApppendEventDetails(const WebMouseEvent& event, std::string* result) {
StringAppendF(result,
- "{\n Button: %d\n Pos: (%d, %d)\n"
- " GlobalPos: (%d, %d)\n Movement: (%d, %d)\n Clicks: %d\n}",
- static_cast<int>(event.button), event.x, event.y, event.globalX,
- event.globalY, event.movementX, event.movementY,
+ "{\n Button: %d\n Pos: (%f, %f)\n"
+ " GlobalPos: (%f, %f)\n Movement: (%d, %d)\n Clicks: %d\n}",
+ static_cast<int>(event.button), event.position.x,
+ event.position.y, event.screenPosition.x,
+ event.screenPosition.y, event.movementX, event.movementY,
event.clickCount);
}

Powered by Google App Engine
This is Rietveld 408576698