Cleanup sf::err
includes
This commit is contained in:
parent
359fe9088c
commit
32ad019304
@ -29,7 +29,7 @@
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/System/Export.hpp>
|
||||
#include <ostream>
|
||||
#include <iosfwd>
|
||||
|
||||
|
||||
namespace sf
|
||||
|
@ -28,6 +28,7 @@
|
||||
#include <SFML/Audio/ALCheck.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <string>
|
||||
#include <ostream>
|
||||
|
||||
#if defined(__APPLE__)
|
||||
#if defined(__clang__)
|
||||
|
@ -30,6 +30,7 @@
|
||||
#include <SFML/Audio/Listener.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <optional>
|
||||
#include <ostream>
|
||||
|
||||
#if defined(__APPLE__)
|
||||
#if defined(__clang__)
|
||||
|
@ -33,8 +33,8 @@
|
||||
#include <SFML/System/MemoryInputStream.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <SFML/System/Time.hpp>
|
||||
#include <iostream>
|
||||
#include <algorithm>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace sf
|
||||
|
@ -32,6 +32,7 @@
|
||||
#include <fstream>
|
||||
#include <algorithm>
|
||||
#include <mutex>
|
||||
#include <ostream>
|
||||
|
||||
#if defined(__APPLE__)
|
||||
#if defined(__clang__)
|
||||
|
@ -34,6 +34,7 @@
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <SFML/System/Time.hpp>
|
||||
#include <memory>
|
||||
#include <ostream>
|
||||
|
||||
#if defined(__APPLE__)
|
||||
#if defined(__clang__)
|
||||
|
@ -29,6 +29,7 @@
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <algorithm>
|
||||
#include <iterator>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace sf
|
||||
|
@ -36,6 +36,7 @@
|
||||
#include <SFML/System/FileInputStream.hpp>
|
||||
#include <SFML/System/MemoryInputStream.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace
|
||||
|
@ -29,6 +29,7 @@
|
||||
#include <SFML/System/InputStream.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <cassert>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace
|
||||
|
@ -47,7 +47,6 @@
|
||||
|
||||
#include <SFML/Audio/SoundFileReaderMp3.hpp>
|
||||
#include <SFML/System/MemoryInputStream.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <algorithm>
|
||||
#include <cstring>
|
||||
|
||||
|
@ -30,6 +30,7 @@
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <cctype>
|
||||
#include <cassert>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace
|
||||
|
@ -32,6 +32,7 @@
|
||||
#include <cctype>
|
||||
#include <cassert>
|
||||
#include <cstring>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include <algorithm>
|
||||
#include <cctype>
|
||||
#include <cassert>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace sf
|
||||
|
@ -29,6 +29,7 @@
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <SFML/System/Utils.hpp>
|
||||
#include <algorithm>
|
||||
#include <ostream>
|
||||
#include <cctype>
|
||||
#include <cstdlib>
|
||||
#include <cassert>
|
||||
|
@ -28,6 +28,7 @@
|
||||
#include <SFML/Audio/SoundFileWriterWav.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <SFML/System/Utils.hpp>
|
||||
#include <ostream>
|
||||
#include <cassert>
|
||||
|
||||
|
||||
|
@ -30,6 +30,7 @@
|
||||
#include <SFML/Audio/ALCheck.hpp>
|
||||
#include <SFML/System/Sleep.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ostream>
|
||||
#include <cstring>
|
||||
#include <cassert>
|
||||
|
||||
|
@ -30,8 +30,9 @@
|
||||
#include <SFML/Audio/ALCheck.hpp>
|
||||
#include <SFML/System/Sleep.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <cassert>
|
||||
#include <mutex>
|
||||
#include <ostream>
|
||||
#include <cassert>
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning(disable: 4355) // 'this' used in base member initializer list
|
||||
|
@ -40,6 +40,7 @@
|
||||
#include FT_BITMAP_H
|
||||
#include FT_STROKER_H
|
||||
#include <type_traits>
|
||||
#include <ostream>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include <cmath>
|
||||
|
@ -28,6 +28,7 @@
|
||||
#include <SFML/Graphics/GLCheck.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <string>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace sf
|
||||
|
@ -37,6 +37,8 @@
|
||||
#include <glad/gl.h>
|
||||
#endif
|
||||
|
||||
#include <ostream>
|
||||
|
||||
#if !defined(GL_MAJOR_VERSION)
|
||||
#define GL_MAJOR_VERSION 0x821B
|
||||
#endif
|
||||
|
@ -32,6 +32,7 @@
|
||||
#include <SFML/System/Android/ResourceStream.hpp>
|
||||
#endif
|
||||
#include <algorithm>
|
||||
#include <ostream>
|
||||
#include <cstring>
|
||||
|
||||
|
||||
|
@ -34,6 +34,7 @@
|
||||
#define STB_IMAGE_WRITE_IMPLEMENTATION
|
||||
#include <stb_image_write.h>
|
||||
#include <iterator>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace
|
||||
|
@ -38,6 +38,7 @@
|
||||
#include <iostream>
|
||||
#include <mutex>
|
||||
#include <unordered_map>
|
||||
#include <ostream>
|
||||
#include <cassert>
|
||||
|
||||
|
||||
|
@ -30,6 +30,7 @@
|
||||
#include <SFML/Graphics/RenderTextureImplDefault.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <memory>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace sf
|
||||
|
@ -36,6 +36,7 @@
|
||||
#include <unordered_map>
|
||||
#include <unordered_set>
|
||||
#include <utility>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace
|
||||
|
@ -37,6 +37,7 @@
|
||||
#include <fstream>
|
||||
#include <vector>
|
||||
#include <mutex>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
#ifndef SFML_OPENGL_ES
|
||||
|
@ -36,6 +36,7 @@
|
||||
#include <cstring>
|
||||
#include <climits>
|
||||
#include <mutex>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace
|
||||
|
@ -32,6 +32,7 @@
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <mutex>
|
||||
#include <utility>
|
||||
#include <ostream>
|
||||
#include <cstddef>
|
||||
#include <cstring>
|
||||
|
||||
|
@ -33,6 +33,7 @@
|
||||
#include <fstream>
|
||||
#include <iterator>
|
||||
#include <sstream>
|
||||
#include <ostream>
|
||||
#include <cstdio>
|
||||
|
||||
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include <iterator>
|
||||
#include <sstream>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace sf
|
||||
|
@ -28,6 +28,7 @@
|
||||
#include <SFML/Network/Socket.hpp>
|
||||
#include <SFML/Network/SocketImpl.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace sf
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <algorithm>
|
||||
#include <memory>
|
||||
#include <ostream>
|
||||
#include <utility>
|
||||
|
||||
#ifdef _MSC_VER
|
||||
|
@ -29,6 +29,7 @@
|
||||
#include <SFML/Network/TcpSocket.hpp>
|
||||
#include <SFML/Network/SocketImpl.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace sf
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include <SFML/Network/SocketImpl.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <algorithm>
|
||||
#include <ostream>
|
||||
#include <cstring>
|
||||
|
||||
#ifdef _MSC_VER
|
||||
|
@ -30,6 +30,7 @@
|
||||
#include <SFML/Network/Packet.hpp>
|
||||
#include <SFML/Network/SocketImpl.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ostream>
|
||||
#include <cstddef>
|
||||
|
||||
|
||||
|
@ -27,6 +27,7 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Network/Unix/SocketImpl.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ostream>
|
||||
#include <cerrno>
|
||||
#include <cstring>
|
||||
#include <fcntl.h>
|
||||
|
@ -28,6 +28,7 @@
|
||||
#include <SFML/Window/Android/ClipboardImpl.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <SFML/System/String.hpp>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace sf
|
||||
|
@ -29,6 +29,7 @@
|
||||
#include <SFML/System/Android/Activity.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <mutex>
|
||||
#include <ostream>
|
||||
#include <jni.h>
|
||||
|
||||
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include <SFML/Window/Event.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <mutex>
|
||||
#include <ostream>
|
||||
#include <android/looper.h>
|
||||
|
||||
// Define missing constants for older API levels
|
||||
|
@ -28,6 +28,7 @@
|
||||
#include <SFML/Window/Context.hpp>
|
||||
#include <SFML/Window/GlContext.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace
|
||||
|
@ -30,6 +30,7 @@
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <glad/egl.h>
|
||||
#include <string>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace sf
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <SFML/System/Sleep.hpp>
|
||||
#include <mutex>
|
||||
#include <ostream>
|
||||
#ifdef SFML_SYSTEM_ANDROID
|
||||
#include <SFML/System/Android/Activity.hpp>
|
||||
#endif
|
||||
|
@ -34,6 +34,7 @@
|
||||
#include <memory>
|
||||
#include <mutex>
|
||||
#include <optional>
|
||||
#include <ostream>
|
||||
#include <string>
|
||||
#include <unordered_map>
|
||||
#include <utility>
|
||||
|
@ -29,6 +29,7 @@
|
||||
#include <SFML/Window/OSX/HIDInputManager.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <AppKit/AppKit.h>
|
||||
#include <ostream>
|
||||
|
||||
namespace sf
|
||||
{
|
||||
|
@ -32,6 +32,7 @@
|
||||
#include <SFML/Window/OSX/InputImpl.hpp>
|
||||
#include <SFML/Window/OSX/HIDInputManager.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ostream>
|
||||
|
||||
#import <SFML/Window/OSX/SFOpenGLView.h>
|
||||
#import <AppKit/AppKit.h>
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include <SFML/Window/OSX/HIDInputManager.hpp>
|
||||
#include <SFML/Window/OSX/HIDJoystickManager.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace
|
||||
|
@ -32,6 +32,7 @@
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <dlfcn.h>
|
||||
#include <stdint.h>
|
||||
#include <ostream>
|
||||
|
||||
#if defined(__APPLE__)
|
||||
#if defined(__clang__)
|
||||
|
@ -28,6 +28,7 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <SFML/Window/OSX/WindowImplCocoa.hpp>
|
||||
#include <ostream>
|
||||
|
||||
#import <SFML/Window/OSX/SFApplication.h>
|
||||
#import <SFML/Window/OSX/SFOpenGLView.h>
|
||||
|
@ -33,6 +33,7 @@
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ApplicationServices/ApplicationServices.h>
|
||||
#include <algorithm>
|
||||
#include <ostream>
|
||||
|
||||
#import <SFML/Window/OSX/NSImage+raw.h>
|
||||
#import <SFML/Window/OSX/Scaling.h>
|
||||
@ -133,7 +134,7 @@
|
||||
|
||||
// Set the view to the window as its content view.
|
||||
[m_window setContentView:m_oglView];
|
||||
|
||||
|
||||
[m_oglView finishInit];
|
||||
}
|
||||
|
||||
|
@ -30,6 +30,7 @@
|
||||
#include <SFML/Window/OSX/cg_sf_conversion.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <algorithm>
|
||||
#include <ostream>
|
||||
|
||||
namespace sf
|
||||
{
|
||||
|
@ -30,6 +30,7 @@
|
||||
#include <SFML/Window/OSX/WindowImplCocoa.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <SFML/System/String.hpp>
|
||||
#include <ostream>
|
||||
|
||||
#import <SFML/Window/OSX/cpp_objc_conversion.h>
|
||||
#import <SFML/Window/OSX/Scaling.h>
|
||||
|
@ -27,6 +27,7 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Window/SensorManager.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace sf
|
||||
|
@ -32,6 +32,7 @@
|
||||
#include <SFML/System/Time.hpp>
|
||||
#include <X11/Xatom.h>
|
||||
#include <vector>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace
|
||||
|
@ -30,6 +30,7 @@
|
||||
#include <X11/keysym.h>
|
||||
#include <mutex>
|
||||
#include <unordered_map>
|
||||
#include <ostream>
|
||||
#include <cassert>
|
||||
#include <cstdlib>
|
||||
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <mutex>
|
||||
#include <vector>
|
||||
#include <ostream>
|
||||
|
||||
// We check for this definition in order to avoid multiple definitions of GLAD
|
||||
// entities during unity builds of SFML.
|
||||
|
@ -31,9 +31,10 @@
|
||||
#include <libudev.h>
|
||||
#include <unistd.h>
|
||||
#include <fcntl.h>
|
||||
#include <cerrno>
|
||||
#include <vector>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <ostream>
|
||||
#include <cerrno>
|
||||
#include <cstring>
|
||||
|
||||
namespace
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include <X11/Xlib.h>
|
||||
#include <X11/extensions/Xrandr.h>
|
||||
#include <algorithm>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace sf
|
||||
|
@ -49,11 +49,12 @@
|
||||
#include <libgen.h>
|
||||
#include <fcntl.h>
|
||||
#include <algorithm>
|
||||
#include <vector>
|
||||
#include <string>
|
||||
#include <cstring>
|
||||
#include <cassert>
|
||||
#include <mutex>
|
||||
#include <ostream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <cassert>
|
||||
#include <cstring>
|
||||
|
||||
#ifdef SFML_OPENGL_ES
|
||||
#include <SFML/Window/EglContext.hpp>
|
||||
|
@ -28,7 +28,8 @@
|
||||
#include <SFML/Window/Win32/ClipboardImpl.hpp>
|
||||
#include <SFML/System/Win32/WindowsHeader.hpp>
|
||||
#include <SFML/System/String.hpp>
|
||||
#include <iostream>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace sf
|
||||
@ -42,13 +43,13 @@ String ClipboardImpl::getString()
|
||||
|
||||
if (!IsClipboardFormatAvailable(CF_UNICODETEXT))
|
||||
{
|
||||
std::cerr << "Failed to get the clipboard data in Unicode format." << std::endl;
|
||||
err() << "Failed to get the clipboard data in Unicode format." << std::endl;
|
||||
return text;
|
||||
}
|
||||
|
||||
if (!OpenClipboard(nullptr))
|
||||
{
|
||||
std::cerr << "Failed to open the Win32 clipboard." << std::endl;
|
||||
err() << "Failed to open the Win32 clipboard." << std::endl;
|
||||
return text;
|
||||
}
|
||||
|
||||
@ -56,7 +57,7 @@ String ClipboardImpl::getString()
|
||||
|
||||
if (!clipboard_handle)
|
||||
{
|
||||
std::cerr << "Failed to get Win32 handle for clipboard content." << std::endl;
|
||||
err() << "Failed to get Win32 handle for clipboard content." << std::endl;
|
||||
CloseClipboard();
|
||||
return text;
|
||||
}
|
||||
@ -74,13 +75,13 @@ void ClipboardImpl::setString(const String& text)
|
||||
{
|
||||
if (!OpenClipboard(nullptr))
|
||||
{
|
||||
std::cerr << "Failed to open the Win32 clipboard." << std::endl;
|
||||
err() << "Failed to open the Win32 clipboard." << std::endl;
|
||||
return;
|
||||
}
|
||||
|
||||
if (!EmptyClipboard())
|
||||
{
|
||||
std::cerr << "Failed to empty the Win32 clipboard." << std::endl;
|
||||
err() << "Failed to empty the Win32 clipboard." << std::endl;
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -28,6 +28,7 @@
|
||||
#include <SFML/Window/Win32/CursorImpl.hpp>
|
||||
#include <SFML/System/Win32/WindowsHeader.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ostream>
|
||||
#include <cstring>
|
||||
|
||||
|
||||
|
@ -32,11 +32,12 @@
|
||||
#include <SFML/System/Time.hpp>
|
||||
#include <tchar.h>
|
||||
#include <regstr.h>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include <ostream>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
|
||||
|
||||
|
||||
|
@ -29,6 +29,7 @@
|
||||
#include <SFML/Window/Win32/WglContext.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <mutex>
|
||||
#include <ostream>
|
||||
#include <sstream>
|
||||
#include <vector>
|
||||
|
||||
|
@ -35,7 +35,9 @@
|
||||
// expects lowercase, and a native compile on windows, whether via msvc
|
||||
// or mingw-w64 addresses files in a case insensitive manner.
|
||||
#include <dbt.h>
|
||||
#include <ostream>
|
||||
#include <vector>
|
||||
|
||||
#include <cstring>
|
||||
|
||||
// MinGW lacks the definition of some Win32 constants
|
||||
|
@ -30,6 +30,7 @@
|
||||
#include <SFML/Window/WindowImpl.hpp>
|
||||
#include <SFML/System/Sleep.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace sf
|
||||
|
@ -29,6 +29,7 @@
|
||||
#include <SFML/Window/ContextSettings.hpp>
|
||||
#include <SFML/Window/WindowImpl.hpp>
|
||||
#include <SFML/System/Err.hpp>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
namespace
|
||||
|
@ -35,6 +35,8 @@
|
||||
#include <OpenGLES/EAGLDrawable.h>
|
||||
#include <QuartzCore/CAEAGLLayer.h>
|
||||
#include <dlfcn.h>
|
||||
#include <ostream>
|
||||
|
||||
|
||||
#if defined(__APPLE__)
|
||||
#if defined(__clang__)
|
||||
|
Loading…
Reference in New Issue
Block a user