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

Unified Diff: third_party/WebKit/Source/web/WebPluginContainerImpl.cpp

Issue 2573073003: Collapse the API surface on WebInputEvent via accessor functions. (Closed)
Patch Set: Created 4 years 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: third_party/WebKit/Source/web/WebPluginContainerImpl.cpp
diff --git a/third_party/WebKit/Source/web/WebPluginContainerImpl.cpp b/third_party/WebKit/Source/web/WebPluginContainerImpl.cpp
index 8b29d6b25593c350c767b998e525d954315181aa..43b7bcf17ec4ee01e7d3cd70cb6a72c5b5319410 100644
--- a/third_party/WebKit/Source/web/WebPluginContainerImpl.cpp
+++ b/third_party/WebKit/Source/web/WebPluginContainerImpl.cpp
@@ -710,7 +710,7 @@ void WebPluginContainerImpl::handleMouseEvent(MouseEvent* event) {
WebMouseEventBuilder webEvent(this, LayoutItem(m_element->layoutObject()),
*event);
- if (webEvent.type == WebInputEvent::Undefined)
+ if (webEvent.type() == WebInputEvent::Undefined)
return;
if (event->type() == EventTypeNames::mousedown)
@@ -762,7 +762,7 @@ void WebPluginContainerImpl::handleDragEvent(MouseEvent* event) {
void WebPluginContainerImpl::handleWheelEvent(WheelEvent* event) {
WebMouseWheelEventBuilder webEvent(
this, LayoutItem(m_element->layoutObject()), *event);
- if (webEvent.type == WebInputEvent::Undefined)
+ if (webEvent.type() == WebInputEvent::Undefined)
return;
WebCursorInfo cursorInfo;
@@ -773,15 +773,15 @@ void WebPluginContainerImpl::handleWheelEvent(WheelEvent* event) {
void WebPluginContainerImpl::handleKeyboardEvent(KeyboardEvent* event) {
WebKeyboardEventBuilder webEvent(*event);
- if (webEvent.type == WebInputEvent::Undefined)
+ if (webEvent.type() == WebInputEvent::Undefined)
return;
- if (webEvent.type == WebInputEvent::KeyDown) {
+ if (webEvent.type() == WebInputEvent::KeyDown) {
#if OS(MACOSX)
- if ((webEvent.modifiers & WebInputEvent::InputModifiers) ==
+ if ((webEvent.modifiers() & WebInputEvent::InputModifiers) ==
WebInputEvent::MetaKey
#else
- if ((webEvent.modifiers & WebInputEvent::InputModifiers) ==
+ if ((webEvent.modifiers() & WebInputEvent::InputModifiers) ==
WebInputEvent::ControlKey
#endif
&& (webEvent.windowsKeyCode == VKEY_C ||
@@ -815,7 +815,7 @@ void WebPluginContainerImpl::handleTouchEvent(TouchEvent* event) {
case TouchEventRequestTypeRaw: {
WebTouchEventBuilder webEvent(LayoutItem(m_element->layoutObject()),
*event);
- if (webEvent.type == WebInputEvent::Undefined)
+ if (webEvent.type() == WebInputEvent::Undefined)
return;
if (event->type() == EventTypeNames::touchstart)
@@ -837,7 +837,7 @@ void WebPluginContainerImpl::handleTouchEvent(TouchEvent* event) {
void WebPluginContainerImpl::handleGestureEvent(GestureEvent* event) {
WebGestureEventBuilder webEvent(LayoutItem(m_element->layoutObject()),
*event);
- if (webEvent.type == WebInputEvent::Undefined)
+ if (webEvent.type() == WebInputEvent::Undefined)
return;
if (event->type() == EventTypeNames::gesturetapdown)
focusPlugin();
@@ -854,7 +854,7 @@ void WebPluginContainerImpl::handleGestureEvent(GestureEvent* event) {
void WebPluginContainerImpl::synthesizeMouseEventIfPossible(TouchEvent* event) {
WebMouseEventBuilder webEvent(this, LayoutItem(m_element->layoutObject()),
*event);
- if (webEvent.type == WebInputEvent::Undefined)
+ if (webEvent.type() == WebInputEvent::Undefined)
return;
WebCursorInfo cursorInfo;

Powered by Google App Engine
This is Rietveld 408576698