diff --git a/include/SFML/System/Unicode.inl b/include/SFML/System/Unicode.inl index 5ddeaabe0..368f7a02b 100644 --- a/include/SFML/System/Unicode.inl +++ b/include/SFML/System/Unicode.inl @@ -132,7 +132,7 @@ inline Out Unicode::UTF8ToUTF16(In begin, In end, Out output, Uint16 replacement else { // Valid character directly convertible to 16 bits - *Output++ = static_cast(character); + *output++ = static_cast(character); } } else if (character > 0x0010FFFF) diff --git a/include/SFML/System/Vector3.inl b/include/SFML/System/Vector3.inl index ccae26700..b26f574f7 100644 --- a/include/SFML/System/Vector3.inl +++ b/include/SFML/System/Vector3.inl @@ -169,7 +169,7 @@ Vector3& operator /=(Vector3& left, T right) /// Operator == overload ; compares the equality of two vectors //////////////////////////////////////////////////////////// template -bool operator ==(const Vector3& left, const Vector3& V2) +bool operator ==(const Vector3& left, const Vector3& right) { return (left.x == right.x) && (left.y == right.y) && (left.z == right.z); } diff --git a/samples/X11/X11.cpp b/samples/X11/X11.cpp index 554aab4fe..28eae8626 100644 --- a/samples/X11/X11.cpp +++ b/samples/X11/X11.cpp @@ -122,7 +122,7 @@ int main() XSetWindowAttributes attributes; attributes.background_pixel = BlackPixel(display, screen); attributes.event_mask = KeyPressMask; - Window window = XCreateWindow(Disp, RootWindow(display, screen), + Window window = XCreateWindow(display, RootWindow(display, screen), 0, 0, 650, 330, 0, DefaultDepth(display, screen), InputOutput, diff --git a/src/SFML/Graphics/Linux/RenderImageImplPBuffer.cpp b/src/SFML/Graphics/Linux/RenderImageImplPBuffer.cpp index c12fbaa07..4f59c93c0 100644 --- a/src/SFML/Graphics/Linux/RenderImageImplPBuffer.cpp +++ b/src/SFML/Graphics/Linux/RenderImageImplPBuffer.cpp @@ -146,7 +146,7 @@ bool RenderImageImplPBuffer::Create(unsigned int width, unsigned int height, uns glXMakeCurrent(myDisplay, NULL, NULL); // Create the context - XVisualInfo* Visual = glXGetVisualFromFBConfig(myDisplay, configs[0]); + XVisualInfo* visual = glXGetVisualFromFBConfig(myDisplay, configs[0]); myContext = glXCreateContext(myDisplay, visual, currentContext, true); if (!myContext) { @@ -173,7 +173,7 @@ bool RenderImageImplPBuffer::Create(unsigned int width, unsigned int height, uns //////////////////////////////////////////////////////////// bool RenderImageImplPBuffer::Activate(bool active) { - if (Active) + if (active) { if (myPBuffer && myContext && (glXGetCurrentContext() != myContext)) { diff --git a/src/SFML/Window/Linux/ContextGLX.cpp b/src/SFML/Window/Linux/ContextGLX.cpp index 5168cedfb..23f28a1c0 100644 --- a/src/SFML/Window/Linux/ContextGLX.cpp +++ b/src/SFML/Window/Linux/ContextGLX.cpp @@ -193,10 +193,10 @@ void ContextGLX::CreateContext(ContextGLX* shared, unsigned int bitsPerPixel, co // Get all the visuals matching the template int nbVisuals = 0; XVisualInfo* visuals = XGetVisualInfo(myDisplay.GetDisplay(), VisualDepthMask | VisualIDMask | VisualScreenMask, &tpl, &nbVisuals); - if (!Visuals || (NbVisuals == 0)) + if (!visuals || (nbVisuals == 0)) { - if (Visuals) - XFree(Visuals); + if (visuals) + XFree(visuals); std::cerr << "There is no valid visual for the selected screen" << std::endl; return; } diff --git a/src/SFML/Window/Linux/VideoModeSupport.cpp b/src/SFML/Window/Linux/VideoModeSupport.cpp index 1c20a1ef8..99c76ffe9 100644 --- a/src/SFML/Window/Linux/VideoModeSupport.cpp +++ b/src/SFML/Window/Linux/VideoModeSupport.cpp @@ -51,7 +51,7 @@ void VideoModeSupport::GetSupportedVideoModes(std::vector& modes) // Check if the XRandR extension is present int version; - if (XQueryExtension(Disp.GetDisplay(), "RANDR", &version, &version, &version)) + if (XQueryExtension(disp.GetDisplay(), "RANDR", &version, &version, &version)) { // Get the current configuration XRRScreenConfiguration* config = XRRGetScreenInfo(disp.GetDisplay(), RootWindow(disp.GetDisplay(), screen)); @@ -125,7 +125,7 @@ VideoMode VideoModeSupport::GetDesktopVideoMode() // Get the available screen sizes int nbSizes; - XRRScreenSize* sizes = XRRConfigSizes(Config, &nbSizes); + XRRScreenSize* sizes = XRRConfigSizes(config, &nbSizes); if (sizes && (nbSizes > 0)) desktopMode = VideoMode(sizes[currentMode].width, sizes[currentMode].height, DefaultDepth(disp.GetDisplay(), screen)); diff --git a/src/SFML/Window/Linux/WindowImplX11.cpp b/src/SFML/Window/Linux/WindowImplX11.cpp index ceb81d330..cbd5aa4a4 100644 --- a/src/SFML/Window/Linux/WindowImplX11.cpp +++ b/src/SFML/Window/Linux/WindowImplX11.cpp @@ -94,7 +94,7 @@ myKeyRepeat (true) myHeight = windowAttributes.height; // Make sure the window is listening to all the requiered events - XSelectInput(myDisplay, myWindow, EventMask & ~ButtonPressMask); + XSelectInput(myDisplay, myWindow, eventMask & ~ButtonPressMask); // Do some common initializations Initialize(); @@ -560,7 +560,7 @@ void WindowImplX11::CreateHiddenCursor() // Create the cursor, using the pixmap as both the shape and the mask of the cursor XColor color; color.flags = DoRed | DoGreen | DoBlue; - color.red = Color.blue = Color.green = 0; + color.red = color.blue = color.green = 0; myHiddenCursor = XCreatePixmapCursor(myDisplay, cursorPixmap, cursorPixmap, &color, &color, 0, 0); // We don't need the pixmap any longer, free it @@ -759,7 +759,7 @@ void WindowImplX11::ProcessEvent(XEvent windowEvent) event.Type = Event::MouseButtonPressed; event.MouseButton.X = windowEvent.xbutton.x; event.MouseButton.Y = windowEvent.xbutton.y; - switch (Button) + switch (button) { case Button1 : event.MouseButton.Button = Mouse::Left; break; case Button2 : event.MouseButton.Button = Mouse::Middle; break; @@ -782,7 +782,7 @@ void WindowImplX11::ProcessEvent(XEvent windowEvent) event.Type = Event::MouseButtonReleased; event.MouseButton.X = windowEvent.xbutton.x; event.MouseButton.Y = windowEvent.xbutton.y; - switch (Button) + switch (button) { case Button1 : event.MouseButton.Button = Mouse::Left; break; case Button2 : event.MouseButton.Button = Mouse::Middle; break;