xbmc
ControllerActivity.h
1 /*
2  * Copyright (C) 2023 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 KODI
12 {
13 namespace GAME
14 {
25 {
26 public:
27  CControllerActivity() = default;
28  ~CControllerActivity() = default;
29 
30  float GetActivation() const { return m_lastActivation; }
31 
32  void OnButtonPress(bool pressed);
33  void OnButtonMotion(float magnitude);
34  void OnAnalogStickMotion(float x, float y);
35  void OnWheelMotion(float position);
36  void OnThrottleMotion(float position);
37  void OnInputFrame();
38 
39 private:
40  float m_lastActivation{0.0f};
41  float m_currentActivation{0.0f};
42 };
43 } // namespace GAME
44 } // namespace KODI
Class to hold state about the current activity of a controller.
Definition: ControllerActivity.h:24
Definition: AudioDecoder.h:18