diff options
author | numzero <numzer0@yandex.ru> | 2023-03-13 18:05:36 +0300 |
---|---|---|
committer | numzero <numzer0@yandex.ru> | 2023-03-13 18:05:36 +0300 |
commit | 6c6821742637a2293a28b9134feac555a0fb9d0f (patch) | |
tree | 8481a6ef77cacb3aa72312f9de6639e12f0919ba | |
parent | b27981043772b209d895cf0414e1213878a6354c (diff) | |
parent | 21c61e99735045682e2b9b70180c9af5ca563b5c (diff) | |
download | irrlicht-6c6821742637a2293a28b9134feac555a0fb9d0f.tar.xz |
Merge branch 'master' into drop-irr-compile-config
-rw-r--r-- | CMakeLists.txt | 2 | ||||
-rw-r--r-- | include/IrrCompileConfig.h | 4 | ||||
-rw-r--r-- | include/irrUString.h | 50 | ||||
-rw-r--r-- | source/Irrlicht/CIrrDeviceLinux.h | 7 | ||||
-rw-r--r-- | source/Irrlicht/CIrrDeviceSDL.cpp | 14 | ||||
-rw-r--r-- | source/Irrlicht/CWriteFile.cpp | 2 |
6 files changed, 27 insertions, 52 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index b7b244a..c289434 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -7,7 +7,7 @@ else() cmake_policy(VERSION 3.9) endif() -set(IRRLICHTMT_REVISION 9) +set(IRRLICHTMT_REVISION 11) project(Irrlicht VERSION 1.9.0.${IRRLICHTMT_REVISION} diff --git a/include/IrrCompileConfig.h b/include/IrrCompileConfig.h index 0271289..da3a602 100644 --- a/include/IrrCompileConfig.h +++ b/include/IrrCompileConfig.h @@ -6,8 +6,8 @@ #define __IRR_COMPILE_CONFIG_H_INCLUDED__
//! Identifies the IrrlichtMt fork customized for the Minetest engine
-#define IRRLICHT_VERSION_MT_REVISION 9
-#define IRRLICHT_VERSION_MT "mt9"
+#define IRRLICHT_VERSION_MT_REVISION 11
+#define IRRLICHT_VERSION_MT "mt11"
//! Irrlicht SDK Version
#define IRRLICHT_VERSION_MAJOR 1
diff --git a/include/irrUString.h b/include/irrUString.h index 61c36b8..b0b730f 100644 --- a/include/irrUString.h +++ b/include/irrUString.h @@ -963,11 +963,11 @@ public: #endif if (sizeof(wchar_t) == 4) - append(reinterpret_cast<const uchar32_t* const>(c)); + append(reinterpret_cast<const uchar32_t*>(c)); else if (sizeof(wchar_t) == 2) - append(reinterpret_cast<const uchar16_t* const>(c)); + append(reinterpret_cast<const uchar16_t*>(c)); else if (sizeof(wchar_t) == 1) - append(reinterpret_cast<const uchar8_t* const>(c)); + append(reinterpret_cast<const uchar8_t*>(c)); } @@ -982,11 +982,11 @@ public: #endif if (sizeof(wchar_t) == 4) - append(reinterpret_cast<const uchar32_t* const>(c), length); + append(reinterpret_cast<const uchar32_t*>(c), length); else if (sizeof(wchar_t) == 2) - append(reinterpret_cast<const uchar16_t* const>(c), length); + append(reinterpret_cast<const uchar16_t*>(c), length); else if (sizeof(wchar_t) == 1) - append(reinterpret_cast<const uchar8_t* const>(c), length); + append(reinterpret_cast<const uchar8_t*>(c), length); } @@ -1116,11 +1116,11 @@ public: ustring16& operator=(const wchar_t* const c) { if (sizeof(wchar_t) == 4) - *this = reinterpret_cast<const uchar32_t* const>(c); + *this = reinterpret_cast<const uchar32_t*>(c); else if (sizeof(wchar_t) == 2) - *this = reinterpret_cast<const uchar16_t* const>(c); + *this = reinterpret_cast<const uchar16_t*>(c); else if (sizeof(wchar_t) == 1) - *this = reinterpret_cast<const uchar8_t* const>(c); + *this = reinterpret_cast<const uchar8_t*>(c); return *this; } @@ -3049,14 +3049,14 @@ public: //! Gets the encoding of the Unicode string this class contains. //! \return An enum describing the current encoding of this string. - const unicode::EUTF_ENCODE getEncoding() const + unicode::EUTF_ENCODE getEncoding() const { return encoding; } //! Gets the endianness of the Unicode string this class contains. //! \return An enum describing the endianness of this string. - const unicode::EUTF_ENDIAN getEndianness() const + unicode::EUTF_ENDIAN getEndianness() const { if (encoding == unicode::EUTFE_UTF16_LE || encoding == unicode::EUTFE_UTF32_LE) @@ -3612,33 +3612,5 @@ inline std::wostream& operator<<(std::wostream& out, const ustring16& in) return out; } -namespace unicode -{ - -//! Hashing algorithm for hashing a ustring. Used for things like unordered_maps. -//! Algorithm taken from std::hash<std::string>. -class hash : public std::unary_function<core::ustring, size_t> -{ - public: - size_t operator()(const core::ustring& s) const - { - size_t ret = 2166136261U; - size_t index = 0; - size_t stride = 1 + s.size_raw() / 10; - - core::ustring::const_iterator i = s.begin(); - while (i != s.end()) - { - // TODO: Don't force u32 on an x64 OS. Make it agnostic. - ret = 16777619U * ret ^ (size_t)s[(u32)index]; - index += stride; - i += stride; - } - return (ret); - } -}; - -} // end namespace unicode - } // end namespace core } // end namespace irr diff --git a/source/Irrlicht/CIrrDeviceLinux.h b/source/Irrlicht/CIrrDeviceLinux.h index 45d3f10..2d8945c 100644 --- a/source/Irrlicht/CIrrDeviceLinux.h +++ b/source/Irrlicht/CIrrDeviceLinux.h @@ -414,6 +414,9 @@ namespace irr // text is utf-8
mutable core::stringc Clipboard;
#endif
+#if defined(_IRR_LINUX_X11_XINPUT2_)
+ int currentTouchedCount;
+#endif
u32 Width, Height;
bool WindowHasFocus;
bool WindowMinimized;
@@ -453,10 +456,6 @@ namespace irr };
core::array<JoystickInfo> ActiveJoysticks;
#endif
-
-#if defined(_IRR_LINUX_X11_XINPUT2_)
- int currentTouchedCount;
-#endif
};
diff --git a/source/Irrlicht/CIrrDeviceSDL.cpp b/source/Irrlicht/CIrrDeviceSDL.cpp index 8dee4d1..711cb56 100644 --- a/source/Irrlicht/CIrrDeviceSDL.cpp +++ b/source/Irrlicht/CIrrDeviceSDL.cpp @@ -233,13 +233,17 @@ CIrrDeviceSDL::CIrrDeviceSDL(const SIrrlichtCreationParameters& param) createKeyMap();
if (CreationParams.Fullscreen) {
+#ifdef _IRR_EMSCRIPTEN_PLATFORM_
SDL_Flags |= SDL_WINDOW_FULLSCREEN;
- } else {
- if (Resizable)
- SDL_Flags |= SDL_WINDOW_RESIZABLE;
- if (CreationParams.WindowMaximized)
- SDL_Flags |= SDL_WINDOW_MAXIMIZED;
+#else
+ SDL_Flags |= SDL_WINDOW_FULLSCREEN_DESKTOP;
+#endif
}
+ if (Resizable)
+ SDL_Flags |= SDL_WINDOW_RESIZABLE;
+ if (CreationParams.WindowMaximized)
+ SDL_Flags |= SDL_WINDOW_MAXIMIZED;
+
if (CreationParams.DriverType == video::EDT_OPENGL)
{
SDL_Flags |= SDL_WINDOW_OPENGL;
diff --git a/source/Irrlicht/CWriteFile.cpp b/source/Irrlicht/CWriteFile.cpp index aa07b49..2af6936 100644 --- a/source/Irrlicht/CWriteFile.cpp +++ b/source/Irrlicht/CWriteFile.cpp @@ -12,7 +12,7 @@ namespace io CWriteFile::CWriteFile(const io::path& fileName, bool append)
-: FileSize(0), Filename(fileName)
+: Filename(fileName), FileSize(0)
{
#ifdef _DEBUG
setDebugName("CWriteFile");
|