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

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

Issue 2884463002: Make event-targeting asynchronous in window server. (Closed)
Patch Set: rebase and use EventTargeter Created 3 years, 7 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 | « no previous file | services/ui/ws/event_dispatcher.cc » ('j') | services/ui/ws/event_dispatcher.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: services/ui/ws/event_dispatcher.h
diff --git a/services/ui/ws/event_dispatcher.h b/services/ui/ws/event_dispatcher.h
index 193786bd6ee5d119c42684623986a3ce9c612e94..7b4c7824ea0d623c77f2cc1a9fab3f3bedb3edfb 100644
--- a/services/ui/ws/event_dispatcher.h
+++ b/services/ui/ws/event_dispatcher.h
@@ -59,6 +59,8 @@ class EventDispatcher : public ServerWindowObserver, public DragCursorUpdater {
// any events to the delegate.
void Reset();
+ const EventTargeter* event_targeter() const { return event_targeter_.get(); }
+
void SetMousePointerDisplayLocation(const gfx::Point& display_location,
const int64_t display_id);
const gfx::Point& mouse_pointer_last_location() const {
@@ -144,6 +146,8 @@ class EventDispatcher : public ServerWindowObserver, public DragCursorUpdater {
// ANY and there is a matching accelerator with PRE_TARGET found, than only
// OnAccelerator() is called. The expectation is after the PRE_TARGET has been
// handled this is again called with an AcceleratorMatchPhase of POST_ONLY.
+ // This may be asynchronous if we need to find the target window for |event|
+ // asynchronously.
void ProcessEvent(const ui::Event& event,
const int64_t display_id,
AcceleratorMatchPhase match_phase);
@@ -170,6 +174,8 @@ class EventDispatcher : public ServerWindowObserver, public DragCursorUpdater {
// This also generates exit events as appropriate. For example, if the mouse
// moves between one window to another an exit is generated on the first.
void ProcessPointerEvent(const ui::PointerEvent& event);
+ void ProcessPointerEventOnFoundTarget(const ui::PointerEvent& event,
+ PointerTarget pointer_target_found);
// Adds |pointer_target| to |pointer_targets_|.
void StartTrackingPointer(int32_t pointer_id,
@@ -182,7 +188,14 @@ class EventDispatcher : public ServerWindowObserver, public DragCursorUpdater {
// pointer sends the appropriate event to the delegate and updates the
// currently tracked PointerTarget appropriately.
void UpdateTargetForPointer(int32_t pointer_id,
- const ui::LocatedEvent& event);
+ const ui::PointerEvent& event,
+ const PointerTarget& pointer_target_found);
+
+ void UpdateNonClientAreaForCurrentWindowOnFoundWindow(
+ DeepestWindow deepest_window);
+
+ void UpdateCursorProviderByLastKnownLocationOnFoundWindow(
+ DeepestWindow deepest_window);
sky 2017/05/30 17:26:02 const DeepestWindow& here and bove?
riajiang 2017/05/31 22:44:03 Done.
// Returns true if any pointers are in the pressed/down state.
bool AreAnyPointersDown() const;
« no previous file with comments | « no previous file | services/ui/ws/event_dispatcher.cc » ('j') | services/ui/ws/event_dispatcher.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698