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

Unified Diff: ui/views/widget/desktop_aura/desktop_screen_x11.h

Issue 1915363002: Rename gfx::Display/Screen to display::Display/Screen in views/wm (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: more cleanups Created 4 years, 8 months 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: 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 fb755d92402795651425133839acbc12e588177d..5c6fdf793a939b8c2561fd6d54839537506f51cc 100644
--- a/ui/views/widget/desktop_aura/desktop_screen_x11.h
+++ b/ui/views/widget/desktop_aura/desktop_screen_x11.h
@@ -11,16 +11,12 @@
#include "base/macros.h"
#include "base/timer/timer.h"
+#include "ui/display/screen.h"
#include "ui/events/platform/platform_event_dispatcher.h"
#include "ui/gfx/display_change_notifier.h"
-#include "ui/gfx/screen.h"
#include "ui/gfx/x/x11_atom_cache.h"
#include "ui/views/views_export.h"
-namespace gfx {
-class Display;
-}
-
typedef unsigned long XID;
typedef XID Window;
typedef struct _XDisplay Display;
@@ -33,25 +29,28 @@ class DesktopScreenX11TestApi;
}
// Our singleton screen implementation that talks to xrandr.
-class VIEWS_EXPORT DesktopScreenX11 : public gfx::Screen,
+class VIEWS_EXPORT DesktopScreenX11 : public display::Screen,
public ui::PlatformEventDispatcher {
public:
DesktopScreenX11();
~DesktopScreenX11() override;
- // Overridden from gfx::Screen:
+ // Overridden from display::Screen:
gfx::Point GetCursorScreenPoint() override;
gfx::NativeWindow GetWindowUnderCursor() override;
gfx::NativeWindow GetWindowAtScreenPoint(const gfx::Point& point) override;
int GetNumDisplays() const override;
- std::vector<gfx::Display> GetAllDisplays() const override;
- gfx::Display GetDisplayNearestWindow(gfx::NativeView window) const override;
- gfx::Display GetDisplayNearestPoint(const gfx::Point& point) const override;
- gfx::Display GetDisplayMatching(const gfx::Rect& match_rect) const override;
- gfx::Display GetPrimaryDisplay() const override;
- void AddObserver(gfx::DisplayObserver* observer) override;
- void RemoveObserver(gfx::DisplayObserver* observer) override;
+ std::vector<display::Display> GetAllDisplays() const override;
+ display::Display GetDisplayNearestWindow(
+ gfx::NativeView window) const override;
+ display::Display GetDisplayNearestPoint(
+ const gfx::Point& point) const override;
+ display::Display GetDisplayMatching(
+ const gfx::Rect& match_rect) const override;
+ display::Display GetPrimaryDisplay() const override;
+ void AddObserver(display::DisplayObserver* observer) override;
+ void RemoveObserver(display::DisplayObserver* observer) override;
// ui::PlatformEventDispatcher:
bool CanDispatchEvent(const ui::PlatformEvent& event) override;
@@ -64,17 +63,17 @@ class VIEWS_EXPORT DesktopScreenX11 : public gfx::Screen,
friend class test::DesktopScreenX11TestApi;
// Constructor used in tests.
- DesktopScreenX11(const std::vector<gfx::Display>& test_displays);
+ DesktopScreenX11(const std::vector<display::Display>& test_displays);
// Builds a list of displays from the current screen information offered by
// the X server.
- std::vector<gfx::Display> BuildDisplaysFromXRandRInfo();
+ std::vector<display::Display> BuildDisplaysFromXRandRInfo();
// We delay updating the display so we can coalesce events.
void ConfigureTimerFired();
// Updates |displays_| and sets FontRenderParams's scale factor.
- void SetDisplaysInternal(const std::vector<gfx::Display>& displays);
+ void SetDisplaysInternal(const std::vector<display::Display>& displays);
Display* xdisplay_;
::Window x_root_window_;
@@ -87,7 +86,7 @@ class VIEWS_EXPORT DesktopScreenX11 : public gfx::Screen,
int xrandr_event_base_;
// The display objects we present to chrome.
- std::vector<gfx::Display> displays_;
+ std::vector<display::Display> displays_;
// The timer to delay configuring outputs. See also the comments in
// Dispatch().
« no previous file with comments | « ui/views/widget/desktop_aura/desktop_screen_win.cc ('k') | ui/views/widget/desktop_aura/desktop_screen_x11.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698