Chromium Code Reviews| Index: ui/events/test/motion_event_test_utils.h |
| diff --git a/ui/events/test/motion_event_test_utils.h b/ui/events/test/motion_event_test_utils.h |
| index 9b83fdc7a02f57a9d6995c6b6a3f80cd0c2f6b73..4a32d2fbe4929946998935b0afc7ed808e60b53f 100644 |
| --- a/ui/events/test/motion_event_test_utils.h |
| +++ b/ui/events/test/motion_event_test_utils.h |
| @@ -44,14 +44,14 @@ struct MockMotionEvent : public MotionEventGeneric { |
| ~MockMotionEvent() override; |
| // Utility methods. |
| - void PressPoint(float x, float y); |
| - void MovePoint(size_t index, float x, float y); |
| - void ReleasePoint(); |
| - void CancelPoint(); |
| - void SetTouchMajor(float new_touch_major); |
| - void SetRawOffset(float raw_offset_x, float raw_offset_y); |
| - void SetToolType(size_t index, ToolType tool_type); |
| - void SetPrimaryPointerId(int id); |
| + MockMotionEvent& PressPoint(float x, float y); |
| + MockMotionEvent& MovePoint(size_t index, float x, float y); |
| + MockMotionEvent& ReleasePoint(); |
| + MockMotionEvent& CancelPoint(); |
| + MockMotionEvent& SetTouchMajor(float new_touch_major); |
| + MockMotionEvent& SetRawOffset(float raw_offset_x, float raw_offset_y); |
| + MockMotionEvent& SetToolType(size_t index, ToolType tool_type); |
| + MockMotionEvent& SetPrimaryPointerId(int id); |
|
sadrul
2015/05/14 22:44:36
Interesting. I haven't seen this pattern used else
jdduke (slow)
2015/05/14 22:49:46
Isn't this pretty common with builder objects (con
sadrul
2015/05/14 22:55:32
Not sure. I don't think we have that many builders
|
| private: |
| void PushPointer(float x, float y); |