mirror of
https://github.com/SFML/SFML.git
synced 2024-11-24 20:31:05 +08:00
Remove deprecated 'Keyboard::Key' enumerators and adjust usages
This commit is contained in:
parent
21d594a765
commit
756a399909
@ -189,11 +189,11 @@ int main()
|
||||
{
|
||||
switch (event.key.code)
|
||||
{
|
||||
case sf::Keyboard::Return: generateTerrain(terrainStagingBuffer.data()); break;
|
||||
case sf::Keyboard::Down: currentSetting = (currentSetting + 1) % settingCount; break;
|
||||
case sf::Keyboard::Up: currentSetting = (currentSetting + settingCount - 1) % settingCount; break;
|
||||
case sf::Keyboard::Left: *(settings[currentSetting].value) -= 0.1f; break;
|
||||
case sf::Keyboard::Right: *(settings[currentSetting].value) += 0.1f; break;
|
||||
case sf::Keyboard::Enter: generateTerrain(terrainStagingBuffer.data()); break;
|
||||
case sf::Keyboard::Down: currentSetting = (currentSetting + 1) % settingCount; break;
|
||||
case sf::Keyboard::Up: currentSetting = (currentSetting + settingCount - 1) % settingCount; break;
|
||||
case sf::Keyboard::Left: *(settings[currentSetting].value) -= 0.1f; break;
|
||||
case sf::Keyboard::Right: *(settings[currentSetting].value) += 0.1f; break;
|
||||
default: break;
|
||||
}
|
||||
}
|
||||
|
@ -150,15 +150,7 @@ public:
|
||||
F15, //!< The F15 key
|
||||
Pause, //!< The Pause key
|
||||
|
||||
KeyCount, //!< Keep last -- the total number of keyboard keys
|
||||
|
||||
// Deprecated values:
|
||||
|
||||
Dash = Hyphen, //!< \deprecated Use Hyphen instead
|
||||
BackSpace = Backspace, //!< \deprecated Use Backspace instead
|
||||
BackSlash = Backslash, //!< \deprecated Use Backslash instead
|
||||
SemiColon = Semicolon, //!< \deprecated Use Semicolon instead
|
||||
Return = Enter //!< \deprecated Use Enter instead
|
||||
KeyCount //!< Keep last -- the total number of keyboard keys
|
||||
};
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
|
Loading…
Reference in New Issue
Block a user