xbmc
EventPollHandle.h
1 /*
2  * Copyright (C) 2016-2018 Team Kodi
3  * This file is part of Kodi - https://kodi.tv
4  *
5  * SPDX-License-Identifier: GPL-2.0-or-later
6  * See LICENSES/README.md for more information.
7  */
8 
9 #pragma once
10 
11 namespace PERIPHERALS
12 {
13 class CEventPollHandle;
14 
19 {
20 public:
21  virtual ~IEventPollCallback(void) = default;
22 
23  virtual void Activate(CEventPollHandle& handle) = 0;
24  virtual void Deactivate(CEventPollHandle& handle) = 0;
25  virtual void HandleEvents(bool bWait) = 0;
26  virtual void Release(CEventPollHandle& handle) = 0;
27 };
28 
36 {
37 public:
42 
47 
51  void Activate();
52 
56  void Deactivate();
57 
63  void HandleEvents(bool bWait);
64 
65 private:
66  IEventPollCallback& m_callback;
67 };
68 } // namespace PERIPHERALS
Definition: RetroPlayerInput.h:15
Handle returned by the event scanner to control scan timing.
Definition: EventPollHandle.h:35
Callback implemented by event scanner.
Definition: EventPollHandle.h:18