Convert empty struct to namespace

This commit is contained in:
Chris Thrasher 2023-01-22 11:04:55 -07:00
parent 72cd8781bb
commit 31d946baa0

View File

@ -32,66 +32,62 @@
#include <X11/Xlib.h> // XKeyEvent
namespace sf::priv
{
////////////////////////////////////////////////////////////
/// \brief sf::priv::KeyboardImpl helper
///
/// This class implements keyboard handling functions
/// to help sf::priv::InputImpl class.
////////////////////////////////////////////////////////////
class KeyboardImpl
namespace sf::priv::KeyboardImpl
{
public:
////////////////////////////////////////////////////////////
/// \copydoc sf::Keyboard::isKeyPressed(Key)
///
////////////////////////////////////////////////////////////
static bool isKeyPressed(Keyboard::Key key);
////////////////////////////////////////////////////////////
/// \copydoc sf::Keyboard::isKeyPressed(Key)
///
////////////////////////////////////////////////////////////
bool isKeyPressed(Keyboard::Key key);
////////////////////////////////////////////////////////////
/// \copydoc sf::Keyboard::isKeyPressed(Scancode)
///
////////////////////////////////////////////////////////////
static bool isKeyPressed(Keyboard::Scancode code);
////////////////////////////////////////////////////////////
/// \copydoc sf::Keyboard::isKeyPressed(Scancode)
///
////////////////////////////////////////////////////////////
bool isKeyPressed(Keyboard::Scancode code);
////////////////////////////////////////////////////////////
/// \copydoc sf::Keyboard::localize
///
////////////////////////////////////////////////////////////
static Keyboard::Scancode delocalize(Keyboard::Key key);
////////////////////////////////////////////////////////////
/// \copydoc sf::Keyboard::localize
///
////////////////////////////////////////////////////////////
Keyboard::Scancode delocalize(Keyboard::Key key);
////////////////////////////////////////////////////////////
/// \copydoc sf::Keyboard::delocalize
///
////////////////////////////////////////////////////////////
static Keyboard::Key localize(Keyboard::Scancode code);
////////////////////////////////////////////////////////////
/// \copydoc sf::Keyboard::delocalize
///
////////////////////////////////////////////////////////////
Keyboard::Key localize(Keyboard::Scancode code);
////////////////////////////////////////////////////////////
/// \copydoc sf::Keyboard::getDescription
///
////////////////////////////////////////////////////////////
static String getDescription(Keyboard::Scancode code);
////////////////////////////////////////////////////////////
/// \copydoc sf::Keyboard::getDescription
///
////////////////////////////////////////////////////////////
String getDescription(Keyboard::Scancode code);
////////////////////////////////////////////////////////////
/// \brief Get the sf::Keyboard::Key from XKeyEvent
///
/// \param event Event from which key is gotten
///
/// \return A key being pressed or released
///
////////////////////////////////////////////////////////////
static Keyboard::Key getKeyFromEvent(XKeyEvent& event);
////////////////////////////////////////////////////////////
/// \brief Get the sf::Keyboard::Key from XKeyEvent
///
/// \param event Event from which key is gotten
///
/// \return A key being pressed or released
///
////////////////////////////////////////////////////////////
Keyboard::Key getKeyFromEvent(XKeyEvent& event);
////////////////////////////////////////////////////////////
/// \brief Get the sf::Keyboard::Scancode from XKeyEvent
///
/// \param event Event from which scancode is gotten
///
/// \return A scancode of a key being pressed or released
///
////////////////////////////////////////////////////////////
static Keyboard::Scancode getScancodeFromEvent(XKeyEvent& event);
};
////////////////////////////////////////////////////////////
/// \brief Get the sf::Keyboard::Scancode from XKeyEvent
///
/// \param event Event from which scancode is gotten
///
/// \return A scancode of a key being pressed or released
///
////////////////////////////////////////////////////////////
Keyboard::Scancode getScancodeFromEvent(XKeyEvent& event);
} // namespace sf::priv
} // namespace sf::priv::KeyboardImpl