Wasn't sure of a good way to word the title.
On windows 7 x64(and possibly other OS's) the sf::Mouse::isButtonPressed() function doesn't take into account OS settings to flip the left and right mouse buttons.
I have my mouse buttons reversed, so the physical right button, should be registered as a left click. However SFML2 still reports it as a right click.
I did a search and couldn't find any mention of this on the forums or bug tracker.
Minimal example:
Set the OS to reverse mouse settings and press the left mouse button while running the following code. sf::Mouse::isButtonPressed() still returns true, though it should not.
#include <SFML/Window.hpp>
int main()
{
sf::Window window(sf::VideoMode(800, 600), "My window");
while (window.isOpen())
{
sf::Event event;
while (window.pollEvent(event))
{
//here, isButtonPressed should return false when hitting the physical left button. and the reverse
//should be true when testing against sf::Mouse::Button::Right
if (sf::Mouse::isButtonPressed(sf::Mouse::Button::Left))
window.close();
}
}