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

Unified Diff: services/ui/ws/user_display_manager.h

Issue 2696963003: Split cursor location from UserDisplayManager. (Closed)
Patch Set: Fix nits. Created 3 years, 10 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
« no previous file with comments | « services/ui/ws/display_manager.cc ('k') | services/ui/ws/user_display_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: services/ui/ws/user_display_manager.h
diff --git a/services/ui/ws/user_display_manager.h b/services/ui/ws/user_display_manager.h
index e712da175a38781823292e4ebe34af6a69e48cc0..00d2732539a5ab152d58b7b524854720a9329149 100644
--- a/services/ui/ws/user_display_manager.h
+++ b/services/ui/ws/user_display_manager.h
@@ -6,18 +6,14 @@
#define SERVICES_UI_WS_USER_DISPLAY_MANAGER_H_
#include <set>
+#include <vector>
-#include "base/atomicops.h"
#include "base/macros.h"
#include "mojo/public/cpp/bindings/binding_set.h"
#include "mojo/public/cpp/bindings/interface_ptr_set.h"
#include "services/ui/public/interfaces/display_manager.mojom.h"
#include "services/ui/ws/user_id.h"
-namespace gfx {
-class Point;
-}
-
namespace ui {
namespace ws {
@@ -48,14 +44,6 @@ class UserDisplayManager : public mojom::DisplayManager {
// Called when the primary display changes.
void OnPrimaryDisplayChanged(int64_t primary_display_id);
- // Called from WindowManagerState when its EventDispatcher receives a mouse
- // event.
- void OnMouseCursorLocationChanged(const gfx::Point& point);
-
- // Returns a read-only handle to the shared memory which contains the global
- // mouse cursor position. Each call returns a new handle.
- mojo::ScopedSharedBufferHandle GetCursorLocationMemory();
-
// Overriden from mojom::DisplayManager:
void AddObserver(mojom::DisplayManagerObserverPtr observer) override;
@@ -72,11 +60,6 @@ class UserDisplayManager : public mojom::DisplayManager {
// Calls OnDisplays() on |observer|.
void CallOnDisplays(mojom::DisplayManagerObserver* observer);
- base::subtle::Atomic32* cursor_location_memory() {
- return reinterpret_cast<base::subtle::Atomic32*>(
- cursor_location_mapping_.get());
- }
-
ws::DisplayManager* display_manager_;
UserDisplayManagerDelegate* delegate_;
@@ -92,20 +75,6 @@ class UserDisplayManager : public mojom::DisplayManager {
mojo::InterfacePtrSet<mojom::DisplayManagerObserver>
display_manager_observers_;
- // The current location of the cursor. This is always kept up to date so we
- // can atomically write this to |cursor_location_memory()| once it is created.
- base::subtle::Atomic32 current_cursor_location_;
-
- // A handle to a shared memory buffer that is one 64 bit integer long. We
- // share this with any client as the same user. This buffer is lazily
- // created on the first access.
- mojo::ScopedSharedBufferHandle cursor_location_handle_;
-
- // The one int32 in |cursor_location_handle_|. When we write to this
- // location, we must always write to it atomically. (On the other side of the
- // mojo connection, this data must be read atomically.)
- mojo::ScopedSharedBufferMapping cursor_location_mapping_;
-
DISALLOW_COPY_AND_ASSIGN(UserDisplayManager);
};
« no previous file with comments | « services/ui/ws/display_manager.cc ('k') | services/ui/ws/user_display_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698