1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef UI_EVENTS_PLATFORM_PLATFORM_EVENT_OBSERVER_H_
6 #define UI_EVENTS_PLATFORM_PLATFORM_EVENT_OBSERVER_H_
8 #include "ui/events/events_export.h"
9 #include "ui/events/platform/platform_event_types.h"
13 // PlatformEventObserver can be installed on a PlatformEventSource, and it
14 // receives all events that are dispatched to the dispatchers.
15 class EVENTS_EXPORT PlatformEventObserver
{
17 // This is called before the dispatcher receives the event.
18 virtual void WillProcessEvent(const PlatformEvent
& event
) = 0;
20 // This is called after the event has been dispatched to the dispatcher(s).
21 virtual void DidProcessEvent(const PlatformEvent
& event
) = 0;
24 virtual ~PlatformEventObserver() {}
29 #endif // UI_EVENTS_PLATFORM_PLATFORM_EVENT_OBSERVER_H_