 Chromium Code Reviews
 Chromium Code Reviews Issue 2327623002:
  X11: Add TestDesktopScreenX11 to simulate mouse movement in ui tests  (Closed)
    
  
    Issue 2327623002:
  X11: Add TestDesktopScreenX11 to simulate mouse movement in ui tests  (Closed) 
  | Index: ui/views/widget/desktop_aura/desktop_screen_x11.h | 
| diff --git a/ui/views/widget/desktop_aura/desktop_screen_x11.h b/ui/views/widget/desktop_aura/desktop_screen_x11.h | 
| index 03f5c6255b03ac75a1684ac4c3fe3836ed4fc073..29298cdc72779bb4e46b4249ec524cff2b60a23e 100644 | 
| --- a/ui/views/widget/desktop_aura/desktop_screen_x11.h | 
| +++ b/ui/views/widget/desktop_aura/desktop_screen_x11.h | 
| @@ -14,6 +14,7 @@ | 
| #include "ui/display/display_change_notifier.h" | 
| #include "ui/display/screen.h" | 
| #include "ui/events/platform/platform_event_dispatcher.h" | 
| +#include "ui/gfx/geometry/point.h" | 
| #include "ui/gfx/x/x11_atom_cache.h" | 
| #include "ui/views/views_export.h" | 
| @@ -102,6 +103,22 @@ class VIEWS_EXPORT DesktopScreenX11 : public display::Screen, | 
| DISALLOW_COPY_AND_ASSIGN(DesktopScreenX11); | 
| }; | 
| +class VIEWS_EXPORT TestDesktopScreenX11 : public DesktopScreenX11 { | 
| 
sky
2016/09/08 23:41:24
Document what this class does and why it's needed.
 
Tom (Use chromium acct)
2016/09/09 01:14:11
Done.
 | 
| + public: | 
| + TestDesktopScreenX11(); | 
| + ~TestDesktopScreenX11() override; | 
| + | 
| + gfx::Point GetCursorScreenPoint() override; | 
| + void SetCursorScreenPoint(const gfx::Point& point); | 
| + | 
| + private: | 
| + gfx::Point cursor_screen_point_; | 
| + | 
| + DISALLOW_COPY_AND_ASSIGN(TestDesktopScreenX11); | 
| +}; | 
| + | 
| +VIEWS_EXPORT TestDesktopScreenX11* GetTestDesktopScreenX11(); | 
| + | 
| } // namespace views | 
| #endif // UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_SCREEN_X11_H_ |