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

Side by Side Diff: services/ui/ws/event_dispatcher.h

Issue 2680883002: Fixes bugs in cursor handling (Closed)
Patch Set: 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 unified diff | Download patch
« no previous file with comments | « services/ui/ws/cursor_unittest.cc ('k') | services/ui/ws/event_dispatcher.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 SERVICES_UI_WS_EVENT_DISPATCHER_H_ 5 #ifndef SERVICES_UI_WS_EVENT_DISPATCHER_H_
6 #define SERVICES_UI_WS_EVENT_DISPATCHER_H_ 6 #define SERVICES_UI_WS_EVENT_DISPATCHER_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <map> 10 #include <map>
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 // and if that's the case, releases the capture. 107 // and if that's the case, releases the capture.
108 void ReleaseCaptureBlockedByAnyModalWindow(); 108 void ReleaseCaptureBlockedByAnyModalWindow();
109 109
110 // Retrieves the ServerWindow of the last mouse move. If there is no valid 110 // Retrieves the ServerWindow of the last mouse move. If there is no valid
111 // window event target this falls back to the root of the display. In general 111 // window event target this falls back to the root of the display. In general
112 // this is not null, but may be null during shutdown. 112 // this is not null, but may be null during shutdown.
113 ServerWindow* mouse_cursor_source_window() const { 113 ServerWindow* mouse_cursor_source_window() const {
114 return mouse_cursor_source_window_; 114 return mouse_cursor_source_window_;
115 } 115 }
116 116
117 // Returns the window the mouse cursor is taken from. This does not take
118 // into account drags. In other words if there is a drag on going the mouse
119 // comes comes from a different window.
120 const ServerWindow* GetWindowForMouseCursor() const;
121
117 // If the mouse cursor is still over |mouse_cursor_source_window_|, updates 122 // If the mouse cursor is still over |mouse_cursor_source_window_|, updates
118 // whether we are in the non-client area. Used when 123 // whether we are in the non-client area. Used when
119 // |mouse_cursor_source_window_| has changed its properties. 124 // |mouse_cursor_source_window_| has changed its properties.
120 void UpdateNonClientAreaForCurrentWindow(); 125 void UpdateNonClientAreaForCurrentWindow();
121 126
122 // Possibly updates the cursor. If we aren't in an implicit capture, we take 127 // Possibly updates the cursor. If we aren't in an implicit capture, we take
123 // the last known location of the mouse pointer, and look for the 128 // the last known location of the mouse pointer, and look for the
124 // ServerWindow* under it. 129 // ServerWindow* under it.
125 void UpdateCursorProviderByLastKnownLocation(); 130 void UpdateCursorProviderByLastKnownLocation();
126 131
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
279 AcceleratorMatchPhase::ANY; 284 AcceleratorMatchPhase::ANY;
280 #endif 285 #endif
281 286
282 DISALLOW_COPY_AND_ASSIGN(EventDispatcher); 287 DISALLOW_COPY_AND_ASSIGN(EventDispatcher);
283 }; 288 };
284 289
285 } // namespace ws 290 } // namespace ws
286 } // namespace ui 291 } // namespace ui
287 292
288 #endif // SERVICES_UI_WS_EVENT_DISPATCHER_H_ 293 #endif // SERVICES_UI_WS_EVENT_DISPATCHER_H_
OLDNEW
« no previous file with comments | « services/ui/ws/cursor_unittest.cc ('k') | services/ui/ws/event_dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698