xbmc
KeymapEnvironment.h
1 /*
2  * Copyright (C) 2017-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 #include "IKeymapEnvironment.h"
12 
14 {
15 public:
16  ~CKeymapEnvironment() override = default;
17 
18  // implementation of IKeymapEnvironment
19  int GetWindowID() const override { return m_windowId; }
20  void SetWindowID(int windowId) override { m_windowId = windowId; }
21  int GetFallthrough(int windowId) const override;
22  bool UseGlobalFallthrough() const override { return true; }
23  bool UseEasterEgg() const override { return true; }
24 
25 private:
26  int m_windowId = -1;
27 };
int GetFallthrough(int windowId) const override
Get the fallthrough window to when a key definition is missing.
Definition: KeymapEnvironment.cpp:13
bool UseEasterEgg() const override
Specify if the agent should monitor for easter egg presses.
Definition: KeymapEnvironment.h:23
Definition: KeymapEnvironment.h:13
int GetWindowID() const override
Get the window ID for which actions should be translated.
Definition: KeymapEnvironment.h:19
bool UseGlobalFallthrough() const override
Specify if the global keymap should be used when the window and fallback window are undefined...
Definition: KeymapEnvironment.h:22
void SetWindowID(int windowId) override
Set the window ID.
Definition: KeymapEnvironment.h:20
Customizes the environment in which keymapping is performed.
Definition: IKeymapEnvironment.h:21