| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 496 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 507 if (event.type() == EventTypeNames::mousemove) | 507 if (event.type() == EventTypeNames::mousemove) |
| 508 type = WebInputEvent::MouseMove; | 508 type = WebInputEvent::MouseMove; |
| 509 else if (event.type() == EventTypeNames::mouseout) | 509 else if (event.type() == EventTypeNames::mouseout) |
| 510 type = WebInputEvent::MouseLeave; | 510 type = WebInputEvent::MouseLeave; |
| 511 else if (event.type() == EventTypeNames::mouseover) | 511 else if (event.type() == EventTypeNames::mouseover) |
| 512 type = WebInputEvent::MouseEnter; | 512 type = WebInputEvent::MouseEnter; |
| 513 else if (event.type() == EventTypeNames::mousedown) | 513 else if (event.type() == EventTypeNames::mousedown) |
| 514 type = WebInputEvent::MouseDown; | 514 type = WebInputEvent::MouseDown; |
| 515 else if (event.type() == EventTypeNames::mouseup) | 515 else if (event.type() == EventTypeNames::mouseup) |
| 516 type = WebInputEvent::MouseUp; | 516 type = WebInputEvent::MouseUp; |
| 517 else if (event.type() == EventTypeNames::contextmenu) | |
| 518 type = WebInputEvent::ContextMenu; | |
| 519 else | 517 else |
| 520 return; // Skip all other mouse events. | 518 return; // Skip all other mouse events. |
| 521 | 519 |
| 522 updateWebMouseEventFromCoreMouseEvent(event, *widget, *renderObject, *this); | 520 updateWebMouseEventFromCoreMouseEvent(event, *widget, *renderObject, *this); |
| 523 | 521 |
| 524 switch (event.button()) { | 522 switch (event.button()) { |
| 525 case LeftButton: | 523 case LeftButton: |
| 526 button = WebMouseEvent::ButtonLeft; | 524 button = WebMouseEvent::ButtonLeft; |
| 527 break; | 525 break; |
| 528 case MiddleButton: | 526 case MiddleButton: |
| (...skipping 281 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 810 modifiers = getWebInputModifiers(event); | 808 modifiers = getWebInputModifiers(event); |
| 811 | 809 |
| 812 globalX = event.screenX(); | 810 globalX = event.screenX(); |
| 813 globalY = event.screenY(); | 811 globalY = event.screenY(); |
| 814 IntPoint localPoint = convertAbsoluteLocationForRenderObject(event.absoluteL
ocation(), *renderObject); | 812 IntPoint localPoint = convertAbsoluteLocationForRenderObject(event.absoluteL
ocation(), *renderObject); |
| 815 x = localPoint.x(); | 813 x = localPoint.x(); |
| 816 y = localPoint.y(); | 814 y = localPoint.y(); |
| 817 } | 815 } |
| 818 | 816 |
| 819 } // namespace blink | 817 } // namespace blink |
| OLD | NEW |