diff --git a/include/IContextManager.h b/include/IContextManager.h index b2d02eaa1..1b8e5bb59 100644 --- a/include/IContextManager.h +++ b/include/IContextManager.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_I_CONTEXT_MANAGER_H_INCLUDED__ -#define __IRR_I_CONTEXT_MANAGER_H_INCLUDED__ +#pragma once #include "SExposedVideoData.h" #include "SIrrCreationParameters.h" @@ -60,4 +59,3 @@ namespace video } // end namespace irr -#endif diff --git a/include/IMeshWriter.h b/include/IMeshWriter.h index 4fb6e40e1..8e98d965a 100644 --- a/include/IMeshWriter.h +++ b/include/IMeshWriter.h @@ -2,9 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_I_MESH_WRITER_H_INCLUDED__ -#define __IRR_I_MESH_WRITER_H_INCLUDED__ - +#pragma once #include "IReferenceCounted.h" #include "EMeshWriterEnums.h" @@ -54,5 +52,4 @@ namespace scene } // end namespace } // end namespace -#endif diff --git a/include/IVideoDriver.h b/include/IVideoDriver.h index 717e85c7a..93269bdaf 100644 --- a/include/IVideoDriver.h +++ b/include/IVideoDriver.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_I_VIDEO_DRIVER_H_INCLUDED__ -#define __IRR_I_VIDEO_DRIVER_H_INCLUDED__ +#pragma once #include "rect.h" #include "SColor.h" @@ -1211,4 +1210,3 @@ namespace video } // end namespace irr -#endif diff --git a/include/IrrCompileConfig.h b/include/IrrCompileConfig.h index 162b13103..7e997a868 100644 --- a/include/IrrCompileConfig.h +++ b/include/IrrCompileConfig.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_COMPILE_CONFIG_H_INCLUDED__ -#define __IRR_COMPILE_CONFIG_H_INCLUDED__ +#pragma once //! Identifies the IrrlichtMt fork customized for the Minetest engine #define IRRLICHT_VERSION_MT_REVISION 12 @@ -29,5 +28,3 @@ #ifndef IRRLICHT_API #define IRRLICHT_API #endif - -#endif // __IRR_COMPILE_CONFIG_H_INCLUDED__ diff --git a/include/Keycodes.h b/include/Keycodes.h index bb22fa6c8..5a62fbb5a 100644 --- a/include/Keycodes.h +++ b/include/Keycodes.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_KEY_CODES_H_INCLUDED__ -#define __IRR_KEY_CODES_H_INCLUDED__ +#pragma once namespace irr { @@ -90,7 +89,7 @@ namespace irr KEY_KEY_X = 0x58, // X key KEY_KEY_Y = 0x59, // Y key KEY_KEY_Z = 0x5A, // Z key - KEY_LWIN = 0x5B, // Left Windows key (Microsoft® Natural® keyboard) + KEY_LWIN = 0x5B, // Left Windows key (Microsoft� Natural� keyboard) KEY_RWIN = 0x5C, // Right Windows key (Natural keyboard) KEY_APPS = 0x5D, // Applications key (Natural keyboard) KEY_SLEEP = 0x5F, // Computer Sleep key @@ -185,5 +184,4 @@ namespace irr } // end namespace irr -#endif diff --git a/include/aabbox3d.h b/include/aabbox3d.h index 905bd1a1b..f69808d73 100644 --- a/include/aabbox3d.h +++ b/include/aabbox3d.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_AABBOX_3D_H_INCLUDED__ -#define __IRR_AABBOX_3D_H_INCLUDED__ +#pragma once #include "irrMath.h" #include "plane3d.h" @@ -364,6 +363,3 @@ class aabbox3d } // end namespace core } // end namespace irr - -#endif - diff --git a/include/coreutil.h b/include/coreutil.h index ab755d9b8..55514c25d 100644 --- a/include/coreutil.h +++ b/include/coreutil.h @@ -2,9 +2,6 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_CORE_UTIL_H_INCLUDED__ -#define __IRR_CORE_UTIL_H_INCLUDED__ - #include "irrString.h" #include "path.h" @@ -202,4 +199,3 @@ inline bool isupper(s32 c) { return c >= 'A' && c <= 'Z'; } } // end namespace core } // end namespace irr -#endif diff --git a/include/dimension2d.h b/include/dimension2d.h index 8eec23975..18a996273 100644 --- a/include/dimension2d.h +++ b/include/dimension2d.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_DIMENSION2D_H_INCLUDED__ -#define __IRR_DIMENSION2D_H_INCLUDED__ +#pragma once #include "irrTypes.h" #include "irrMath.h" // for irr::core::equals() @@ -220,5 +219,4 @@ namespace core } // end namespace core } // end namespace irr -#endif diff --git a/include/irrArray.h b/include/irrArray.h index 3c57e5f74..eef7be1b4 100644 --- a/include/irrArray.h +++ b/include/irrArray.h @@ -2,9 +2,7 @@ // This file is part of the "Irrlicht Engine" and the "irrXML" project. // For conditions of distribution and use, see copyright notice in irrlicht.h and irrXML.h -#ifndef __IRR_ARRAY_H_INCLUDED__ -#define __IRR_ARRAY_H_INCLUDED__ - +#pragma once #include #include #include @@ -438,5 +436,4 @@ class array } // end namespace core } // end namespace irr -#endif diff --git a/include/irrMath.h b/include/irrMath.h index 0ff4025da..e3b75e02e 100644 --- a/include/irrMath.h +++ b/include/irrMath.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_MATH_H_INCLUDED__ -#define __IRR_MATH_H_INCLUDED__ +#pragma once #include "irrTypes.h" #include @@ -479,4 +478,3 @@ namespace core using irr::core::IR; using irr::core::FR; -#endif diff --git a/include/irrString.h b/include/irrString.h index b44d872b3..111679240 100644 --- a/include/irrString.h +++ b/include/irrString.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine" and the "irrXML" project. // For conditions of distribution and use, see copyright notice in irrlicht.h and irrXML.h -#ifndef __IRR_STRING_H_INCLUDED__ -#define __IRR_STRING_H_INCLUDED__ +#pragma once #include "irrTypes.h" #include @@ -1025,5 +1024,4 @@ static size_t wStringToMultibyte(string& destination, const wchar_t* source, } // end namespace core } // end namespace irr -#endif diff --git a/include/irrTypes.h b/include/irrTypes.h index 67a01eb5e..097fc0779 100644 --- a/include/irrTypes.h +++ b/include/irrTypes.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_TYPES_H_INCLUDED__ -#define __IRR_TYPES_H_INCLUDED__ +#pragma once #include @@ -120,4 +119,3 @@ code like 'code', but some generate warnings so we use this macro here */ ((irr::u32)(irr::u8)(c0) | ((irr::u32)(irr::u8)(c1) << 8) | \ ((irr::u32)(irr::u8)(c2) << 16) | ((irr::u32)(irr::u8)(c3) << 24 )) -#endif // __IRR_TYPES_H_INCLUDED__ diff --git a/include/line2d.h b/include/line2d.h index f010760a9..71b3c8e9f 100644 --- a/include/line2d.h +++ b/include/line2d.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_LINE_2D_H_INCLUDED__ -#define __IRR_LINE_2D_H_INCLUDED__ +#pragma once #include "irrTypes.h" #include "vector2d.h" @@ -355,5 +354,4 @@ class line2d } // end namespace core } // end namespace irr -#endif diff --git a/include/line3d.h b/include/line3d.h index 6488834e5..796bcc953 100644 --- a/include/line3d.h +++ b/include/line3d.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_LINE_3D_H_INCLUDED__ -#define __IRR_LINE_3D_H_INCLUDED__ +#pragma once #include "irrTypes.h" #include "vector3d.h" @@ -140,5 +139,4 @@ class line3d } // end namespace core } // end namespace irr -#endif diff --git a/include/matrix4.h b/include/matrix4.h index 3f67ac57a..8e8c83b0c 100644 --- a/include/matrix4.h +++ b/include/matrix4.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_MATRIX_H_INCLUDED__ -#define __IRR_MATRIX_H_INCLUDED__ +#pragma once #include "irrMath.h" #include "vector3d.h" @@ -2363,5 +2362,4 @@ namespace core } // end namespace core } // end namespace irr -#endif diff --git a/include/path.h b/include/path.h index 1ce2f269b..5bda3e4de 100644 --- a/include/path.h +++ b/include/path.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine" and the "irrXML" project. // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_PATH_H_INCLUDED__ -#define __IRR_PATH_H_INCLUDED__ +#pragma once #include "irrString.h" @@ -87,4 +86,3 @@ struct SNamedPath } // io } // irr -#endif // __IRR_PATH_H_INCLUDED__ diff --git a/include/plane3d.h b/include/plane3d.h index fde42b7df..b2df1201e 100644 --- a/include/plane3d.h +++ b/include/plane3d.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_PLANE_3D_H_INCLUDED__ -#define __IRR_PLANE_3D_H_INCLUDED__ +#pragma once #include "irrMath.h" #include "vector3d.h" @@ -241,5 +240,4 @@ typedef plane3d plane3di; } // end namespace core } // end namespace irr -#endif diff --git a/include/position2d.h b/include/position2d.h index 05a27c62d..92a35a630 100644 --- a/include/position2d.h +++ b/include/position2d.h @@ -5,8 +5,7 @@ //! As of Irrlicht 1.6, position2d is a synonym for vector2d. /** You should consider position2d to be deprecated, and use vector2d by preference. */ -#ifndef __IRR_POSITION_H_INCLUDED__ -#define __IRR_POSITION_H_INCLUDED__ +#pragma once #include "vector2d.h" @@ -28,5 +27,4 @@ typedef vector2d position2di; // ...and use a #define to catch the rest, for (e.g.) position2d #define position2d vector2d -#endif // __IRR_POSITION_H_INCLUDED__ diff --git a/include/quaternion.h b/include/quaternion.h index 0be0b552e..920339269 100644 --- a/include/quaternion.h +++ b/include/quaternion.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_QUATERNION_H_INCLUDED__ -#define __IRR_QUATERNION_H_INCLUDED__ +#pragma once #include "irrTypes.h" #include "irrMath.h" @@ -754,5 +753,4 @@ inline core::quaternion& quaternion::rotationFromTo(const vector3df& from, const } // end namespace core } // end namespace irr -#endif diff --git a/include/rect.h b/include/rect.h index d2cea1e52..f4acfdc08 100644 --- a/include/rect.h +++ b/include/rect.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_RECT_H_INCLUDED__ -#define __IRR_RECT_H_INCLUDED__ +#pragma once #include "irrTypes.h" #include "dimension2d.h" @@ -284,5 +283,4 @@ namespace core } // end namespace core } // end namespace irr -#endif diff --git a/include/triangle3d.h b/include/triangle3d.h index 721b02eba..5d94eb037 100644 --- a/include/triangle3d.h +++ b/include/triangle3d.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_TRIANGLE_3D_H_INCLUDED__ -#define __IRR_TRIANGLE_3D_H_INCLUDED__ +#pragma once #include "vector3d.h" #include "line3d.h" @@ -274,5 +273,4 @@ namespace core } // end namespace core } // end namespace irr -#endif diff --git a/include/vector2d.h b/include/vector2d.h index 6736d67d5..a987a0ed8 100644 --- a/include/vector2d.h +++ b/include/vector2d.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_POINT_2D_H_INCLUDED__ -#define __IRR_POINT_2D_H_INCLUDED__ +#pragma once #include "irrMath.h" #include "dimension2d.h" @@ -432,5 +431,4 @@ struct hash > } -#endif diff --git a/include/vector3d.h b/include/vector3d.h index 72b34556f..eea90c8df 100644 --- a/include/vector3d.h +++ b/include/vector3d.h @@ -2,8 +2,7 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifndef __IRR_POINT_3D_H_INCLUDED__ -#define __IRR_POINT_3D_H_INCLUDED__ +#pragma once #include "irrMath.h" @@ -485,5 +484,4 @@ struct hash > } -#endif