mirror of
https://github.com/ciphervance/supercell-wx.git
synced 2025-10-30 22:40:05 +00:00
Add hotkey settings
This commit is contained in:
parent
22e3101c22
commit
3da1d15470
7 changed files with 272 additions and 1 deletions
42
scwx-qt/source/scwx/qt/settings/hotkey_settings.hpp
Normal file
42
scwx-qt/source/scwx/qt/settings/hotkey_settings.hpp
Normal file
|
|
@ -0,0 +1,42 @@
|
|||
#pragma once
|
||||
|
||||
#include <scwx/qt/settings/settings_category.hpp>
|
||||
#include <scwx/qt/settings/settings_variable.hpp>
|
||||
#include <scwx/qt/types/hotkey_types.hpp>
|
||||
|
||||
#include <memory>
|
||||
#include <string>
|
||||
|
||||
namespace scwx
|
||||
{
|
||||
namespace qt
|
||||
{
|
||||
namespace settings
|
||||
{
|
||||
|
||||
class HotkeySettings : public SettingsCategory
|
||||
{
|
||||
public:
|
||||
explicit HotkeySettings();
|
||||
~HotkeySettings();
|
||||
|
||||
HotkeySettings(const HotkeySettings&) = delete;
|
||||
HotkeySettings& operator=(const HotkeySettings&) = delete;
|
||||
|
||||
HotkeySettings(HotkeySettings&&) noexcept;
|
||||
HotkeySettings& operator=(HotkeySettings&&) noexcept;
|
||||
|
||||
SettingsVariable<std::string>& hotkey(scwx::qt::types::Hotkey hotkey) const;
|
||||
|
||||
static HotkeySettings& Instance();
|
||||
|
||||
friend bool operator==(const HotkeySettings& lhs, const HotkeySettings& rhs);
|
||||
|
||||
private:
|
||||
class Impl;
|
||||
std::unique_ptr<Impl> p;
|
||||
};
|
||||
|
||||
} // namespace settings
|
||||
} // namespace qt
|
||||
} // namespace scwx
|
||||
Loading…
Add table
Add a link
Reference in a new issue