1
0
mirror of synced 2024-11-12 01:40:47 +01:00

Rename KeyMapping method

This commit is contained in:
Stepland 2020-02-08 16:00:31 +01:00
parent 049544efc1
commit b4cedf0598
2 changed files with 2 additions and 2 deletions

View File

@ -53,7 +53,7 @@ KeyMapping::KeyMapping() {
}
}
void KeyMapping::setPanelToKey(const Button& button, const sf::Keyboard::Key& key) {
void KeyMapping::set_button_to_key(const Button& button, const sf::Keyboard::Key& key) {
if (m_key_to_button.find(key) != m_key_to_button.end()) {
m_button_to_key.erase(m_key_to_button[key]);
m_key_to_button.erase(key);

View File

@ -37,7 +37,7 @@ std::optional<Button> fromIndex(unsigned int index);
class KeyMapping {
public:
KeyMapping();
void setPanelToKey(const Button& button, const sf::Keyboard::Key& key);
void set_button_to_key(const Button& button, const sf::Keyboard::Key& key);
std::optional<Button> key_to_button(const sf::Keyboard::Key& key);
std::optional<sf::Keyboard::Key> button_to_key(const Button& button);
private: