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

Unified Diff: third_party/WebKit/Source/core/editing/SelectionController.cpp

Issue 2227563003: Refactoring button field and its type (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix new instances 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 | « third_party/WebKit/Source/core/dom/Node.cpp ('k') | third_party/WebKit/Source/core/events/MouseEvent.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/editing/SelectionController.cpp
diff --git a/third_party/WebKit/Source/core/editing/SelectionController.cpp b/third_party/WebKit/Source/core/editing/SelectionController.cpp
index a079a51049e3e9e42e895a375a3eb1fde3484b08..2a2de00affe2c588c740a2593162894d6dc99f54 100644
--- a/third_party/WebKit/Source/core/editing/SelectionController.cpp
+++ b/third_party/WebKit/Source/core/editing/SelectionController.cpp
@@ -408,7 +408,7 @@ bool SelectionController::handleMousePressEventDoubleClick(const MouseEventWithH
if (!m_mouseDownAllowsMultiClick)
return handleMousePressEventSingleClick(event);
- if (event.event().button() != LeftButton)
+ if (event.event().pointerProperties().button != WebPointerProperties::Button::Left)
return false;
if (selection().isRange()) {
@@ -436,7 +436,7 @@ bool SelectionController::handleMousePressEventTripleClick(const MouseEventWithH
if (!m_mouseDownAllowsMultiClick)
return handleMousePressEventSingleClick(event);
- if (event.event().button() != LeftButton)
+ if (event.event().pointerProperties().button != WebPointerProperties::Button::Left)
return false;
Node* innerNode = event.innerNode();
@@ -514,7 +514,7 @@ bool SelectionController::handleMouseReleaseEvent(const MouseEventWithHitTestRes
if (m_mouseDownWasSingleClickInSelection && m_selectionState != SelectionState::ExtendedSelection
&& dragStartPos == event.event().position()
&& selection().isRange()
- && event.event().button() != RightButton) {
+ && event.event().pointerProperties().button != WebPointerProperties::Button::Right) {
VisibleSelectionInFlatTree newSelection;
Node* node = event.innerNode();
bool caretBrowsing = m_frame->settings() && m_frame->settings()->caretBrowsingEnabled();
@@ -532,7 +532,7 @@ bool SelectionController::handleMouseReleaseEvent(const MouseEventWithHitTestRes
selection().selectFrameElementInParentIfFullySelected();
- if (event.event().button() == MiddleButton && !event.isOverLink()) {
+ if (event.event().pointerProperties().button == WebPointerProperties::Button::Middle && !event.isOverLink()) {
// Ignore handled, since we want to paste to where the caret was placed anyway.
handled = handlePasteGlobalSelection(event.event()) || handled;
}
« no previous file with comments | « third_party/WebKit/Source/core/dom/Node.cpp ('k') | third_party/WebKit/Source/core/events/MouseEvent.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698