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

Side by Side Diff: ui/views/widget/desktop_aura/desktop_screen_x11.h

Issue 678073003: Standardize usage of virtual/override/final specifiers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_SCREEN_X11_H_ 5 #ifndef UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_SCREEN_X11_H_
6 #define UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_SCREEN_X11_H_ 6 #define UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_SCREEN_X11_H_
7 7
8 #include "base/timer/timer.h" 8 #include "base/timer/timer.h"
9 #include "ui/events/platform/platform_event_dispatcher.h" 9 #include "ui/events/platform/platform_event_dispatcher.h"
10 #include "ui/gfx/display_change_notifier.h" 10 #include "ui/gfx/display_change_notifier.h"
(...skipping 10 matching lines...) Expand all
21 21
22 namespace views { 22 namespace views {
23 class DesktopScreenX11Test; 23 class DesktopScreenX11Test;
24 24
25 // Our singleton screen implementation that talks to xrandr. 25 // Our singleton screen implementation that talks to xrandr.
26 class VIEWS_EXPORT DesktopScreenX11 : public gfx::Screen, 26 class VIEWS_EXPORT DesktopScreenX11 : public gfx::Screen,
27 public ui::PlatformEventDispatcher { 27 public ui::PlatformEventDispatcher {
28 public: 28 public:
29 DesktopScreenX11(); 29 DesktopScreenX11();
30 30
31 virtual ~DesktopScreenX11(); 31 ~DesktopScreenX11() override;
32 32
33 // Overridden from gfx::Screen: 33 // Overridden from gfx::Screen:
34 virtual gfx::Point GetCursorScreenPoint() override; 34 gfx::Point GetCursorScreenPoint() override;
35 virtual gfx::NativeWindow GetWindowUnderCursor() override; 35 gfx::NativeWindow GetWindowUnderCursor() override;
36 virtual gfx::NativeWindow GetWindowAtScreenPoint(const gfx::Point& point) 36 gfx::NativeWindow GetWindowAtScreenPoint(const gfx::Point& point) override;
37 override; 37 int GetNumDisplays() const override;
38 virtual int GetNumDisplays() const override; 38 std::vector<gfx::Display> GetAllDisplays() const override;
39 virtual std::vector<gfx::Display> GetAllDisplays() const override; 39 gfx::Display GetDisplayNearestWindow(gfx::NativeView window) const override;
40 virtual gfx::Display GetDisplayNearestWindow( 40 gfx::Display GetDisplayNearestPoint(const gfx::Point& point) const override;
41 gfx::NativeView window) const override; 41 gfx::Display GetDisplayMatching(const gfx::Rect& match_rect) const override;
42 virtual gfx::Display GetDisplayNearestPoint( 42 gfx::Display GetPrimaryDisplay() const override;
43 const gfx::Point& point) const override; 43 void AddObserver(gfx::DisplayObserver* observer) override;
44 virtual gfx::Display GetDisplayMatching( 44 void RemoveObserver(gfx::DisplayObserver* observer) override;
45 const gfx::Rect& match_rect) const override;
46 virtual gfx::Display GetPrimaryDisplay() const override;
47 virtual void AddObserver(gfx::DisplayObserver* observer) override;
48 virtual void RemoveObserver(gfx::DisplayObserver* observer) override;
49 45
50 // ui::PlatformEventDispatcher: 46 // ui::PlatformEventDispatcher:
51 virtual bool CanDispatchEvent(const ui::PlatformEvent& event) override; 47 bool CanDispatchEvent(const ui::PlatformEvent& event) override;
52 virtual uint32_t DispatchEvent(const ui::PlatformEvent& event) override; 48 uint32_t DispatchEvent(const ui::PlatformEvent& event) override;
53 49
54 private: 50 private:
55 friend class DesktopScreenX11Test; 51 friend class DesktopScreenX11Test;
56 52
57 // Constructor used in tests. 53 // Constructor used in tests.
58 DesktopScreenX11(const std::vector<gfx::Display>& test_displays); 54 DesktopScreenX11(const std::vector<gfx::Display>& test_displays);
59 55
60 // Builds a list of displays from the current screen information offered by 56 // Builds a list of displays from the current screen information offered by
61 // the X server. 57 // the X server.
62 std::vector<gfx::Display> BuildDisplaysFromXRandRInfo(); 58 std::vector<gfx::Display> BuildDisplaysFromXRandRInfo();
(...skipping 19 matching lines...) Expand all
82 scoped_ptr<base::OneShotTimer<DesktopScreenX11> > configure_timer_; 78 scoped_ptr<base::OneShotTimer<DesktopScreenX11> > configure_timer_;
83 79
84 gfx::DisplayChangeNotifier change_notifier_; 80 gfx::DisplayChangeNotifier change_notifier_;
85 81
86 DISALLOW_COPY_AND_ASSIGN(DesktopScreenX11); 82 DISALLOW_COPY_AND_ASSIGN(DesktopScreenX11);
87 }; 83 };
88 84
89 } // namespace views 85 } // namespace views
90 86
91 #endif // UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_SCREEN_X11_H_ 87 #endif // UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_SCREEN_X11_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698