diff --git a/Source/Editor/Cooker/Platform/Mac/MacPlatformTools.cpp b/Source/Editor/Cooker/Platform/Mac/MacPlatformTools.cpp index dd05e0bec..2ccf41aba 100644 --- a/Source/Editor/Cooker/Platform/Mac/MacPlatformTools.cpp +++ b/Source/Editor/Cooker/Platform/Mac/MacPlatformTools.cpp @@ -229,8 +229,6 @@ bool MacPlatformTools::OnPostProcess(CookingData& data) // TODO: sign binaries - // TODO: expose event to inject custom post-processing before app packaging (eg. third-party plugins) - // Package application const auto buildSettings = BuildSettings::Get(); if (buildSettings->SkipPackaging) diff --git a/Source/Engine/Platform/Android/AndroidWindow.h b/Source/Engine/Platform/Android/AndroidWindow.h index 7fca1111d..367c9b16e 100644 --- a/Source/Engine/Platform/Android/AndroidWindow.h +++ b/Source/Engine/Platform/Android/AndroidWindow.h @@ -23,7 +23,7 @@ public: public: - // [Window] + // [WindowBase] void* GetNativePtr() const override; void Show() override; void Hide() override; diff --git a/Source/Engine/Platform/Apple/ApplePlatform.cpp b/Source/Engine/Platform/Apple/ApplePlatform.cpp index 4d12fcf80..4ad126ecb 100644 --- a/Source/Engine/Platform/Apple/ApplePlatform.cpp +++ b/Source/Engine/Platform/Apple/ApplePlatform.cpp @@ -46,6 +46,7 @@ CPUInfo Cpu; String UserLocale; double SecondsPerCycle; +NSAutoreleasePool* AutoreleasePool = nullptr; float ApplePlatform::ScreenScale = 1.0f; @@ -268,11 +269,16 @@ bool ApplePlatform::Init() OnPlatformUserAdd(New(username)); } + AutoreleasePool = [[NSAutoreleasePool alloc] init]; + return false; } void ApplePlatform::Tick() { + // TODO: do it once every X fames + [AutoreleasePool drain]; + AutoreleasePool = [[NSAutoreleasePool alloc] init]; } void ApplePlatform::BeforeExit() diff --git a/Source/Engine/Platform/GDK/GDKWindow.h b/Source/Engine/Platform/GDK/GDKWindow.h index 9856559de..e091f5f04 100644 --- a/Source/Engine/Platform/GDK/GDKWindow.h +++ b/Source/Engine/Platform/GDK/GDKWindow.h @@ -17,7 +17,6 @@ class FLAXENGINE_API GDKWindow : public WindowBase private: Windows::HWND _handle; - Float2 _clientSize; public: @@ -77,7 +76,7 @@ private: public: - // [Window] + // [WindowBase] void* GetNativePtr() const override; void Show() override; void Hide() override; diff --git a/Source/Engine/Platform/Linux/LinuxWindow.h b/Source/Engine/Platform/Linux/LinuxWindow.h index f1a6ee587..52c039f6f 100644 --- a/Source/Engine/Platform/Linux/LinuxWindow.h +++ b/Source/Engine/Platform/Linux/LinuxWindow.h @@ -65,7 +65,7 @@ private: public: - // [Window] + // [WindowBase] void* GetNativePtr() const override; void Show() override; void Hide() override; diff --git a/Source/Engine/Platform/Mac/MacWindow.h b/Source/Engine/Platform/Mac/MacWindow.h index 2a554163c..8850f80ba 100644 --- a/Source/Engine/Platform/Mac/MacWindow.h +++ b/Source/Engine/Platform/Mac/MacWindow.h @@ -14,7 +14,6 @@ class FLAXENGINE_API MacWindow : public WindowBase { private: - Float2 _clientSize; void* _window; bool _isMouseOver = false; @@ -28,7 +27,7 @@ public: public: - // [Window] + // [WindowBase] void* GetNativePtr() const override; void Show() override; void Hide() override; diff --git a/Source/Engine/Platform/UWP/UWPWindow.h b/Source/Engine/Platform/UWP/UWPWindow.h index 8e4a62bb8..1d89cdd00 100644 --- a/Source/Engine/Platform/UWP/UWPWindow.h +++ b/Source/Engine/Platform/UWP/UWPWindow.h @@ -150,7 +150,7 @@ private: public: - // [Window] + // [WindowBase] void* GetNativePtr() const override { return _impl->GetHandle(); diff --git a/Source/Engine/Platform/Windows/WindowsWindow.h b/Source/Engine/Platform/Windows/WindowsWindow.h index d99cfcb15..74e923f86 100644 --- a/Source/Engine/Platform/Windows/WindowsWindow.h +++ b/Source/Engine/Platform/Windows/WindowsWindow.h @@ -30,7 +30,6 @@ private: bool _clipCursorSet = false; bool _isDuringMaximize = false; Windows::HANDLE _monitor = nullptr; - Float2 _clientSize; Windows::LONG _clipCursorRect[4]; int32 _regionWidth = 0, _regionHeight = 0; @@ -95,7 +94,7 @@ private: public: - // [Window] + // [WindowBase] void* GetNativePtr() const override; void Show() override; void Hide() override;