diff --git a/Code/Editor/Util/GuidUtil.cpp b/Code/Editor/Util/GuidUtil.cpp index e8ea6fd3f8..dbd7d4c371 100644 --- a/Code/Editor/Util/GuidUtil.cpp +++ b/Code/Editor/Util/GuidUtil.cpp @@ -11,7 +11,7 @@ const char* GuidUtil::ToString(REFGUID guid) { static char guidString[64]; - sprintf_s(guidString, "{%.8" GUID_FORMAT_DATA1 "-%.4X-%.4X-%.2X%.2X-%.2X%.2X%.2X%.2X%.2X%.2X}", guid.Data1, guid.Data2, guid.Data3, guid.Data4[0], guid.Data4[1], + azsprintf(guidString, "{%.8" GUID_FORMAT_DATA1 "-%.4X-%.4X-%.2X%.2X-%.2X%.2X%.2X%.2X%.2X%.2X}", guid.Data1, guid.Data2, guid.Data3, guid.Data4[0], guid.Data4[1], guid.Data4[2], guid.Data4[3], guid.Data4[4], guid.Data4[5], guid.Data4[6], guid.Data4[7]); return guidString; } diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/ToolsFileUtils/ToolsFileUtils_generic.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/ToolsFileUtils/ToolsFileUtils_generic.cpp new file mode 100644 index 0000000000..8357a265ba --- /dev/null +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/ToolsFileUtils/ToolsFileUtils_generic.cpp @@ -0,0 +1,47 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include "ToolsFileUtils.h" +#include +#include + +#include + +namespace AzToolsFramework +{ + namespace ToolsFileUtils + { + bool SetModificationTime(const char* const filename, AZ::u64 modificationTime) + { + struct stat statResult; + if (stat(filename, &statResult) != 0) + { + return false; + } + + struct utimbuf puttime; + puttime.modtime = modificationTime; + puttime.actime = static_cast(statResult.st_ctime); + + if (utime(filename, &puttime) == 0) + { + return true; + } + + return false; + } + + bool GetFreeDiskSpace(const QString& path, qint64& outFreeDiskSpace) + { + QStorageInfo storageInfo(path); + outFreeDiskSpace = storageInfo.bytesFree(); + + return outFreeDiskSpace >= 0; + } + } +} diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/UI/PropertyEditor/PropertyColorCtrl.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/UI/PropertyEditor/PropertyColorCtrl.cpp index fd6580225f..fae24d9b3a 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/UI/PropertyEditor/PropertyColorCtrl.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/UI/PropertyEditor/PropertyColorCtrl.cpp @@ -18,7 +18,7 @@ AZ_PUSH_DISABLE_WARNING(4251, "-Wunknown-warning-option") #include AZ_POP_DISABLE_WARNING #include -#include +#include namespace AzToolsFramework { diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/aztoolsframework_linux_files.cmake b/Code/Framework/AzToolsFramework/AzToolsFramework/aztoolsframework_linux_files.cmake index af4bfcb8f4..afd487daf7 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/aztoolsframework_linux_files.cmake +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/aztoolsframework_linux_files.cmake @@ -29,4 +29,5 @@ set(FILES UI/UICore/SaveChangesDialog.hxx UI/UICore/SaveChangesDialog.cpp UI/UICore/SaveChangesDialog.ui + ToolsFileUtils/ToolsFileUtils_generic.cpp ) diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/aztoolsframework_mac_files.cmake b/Code/Framework/AzToolsFramework/AzToolsFramework/aztoolsframework_mac_files.cmake index af4bfcb8f4..afd487daf7 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/aztoolsframework_mac_files.cmake +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/aztoolsframework_mac_files.cmake @@ -29,4 +29,5 @@ set(FILES UI/UICore/SaveChangesDialog.hxx UI/UICore/SaveChangesDialog.cpp UI/UICore/SaveChangesDialog.ui + ToolsFileUtils/ToolsFileUtils_generic.cpp ) diff --git a/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/CommandCallbacks.cpp b/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/CommandCallbacks.cpp index a04e2a87c8..c53c382d34 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/CommandCallbacks.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/CommandCallbacks.cpp @@ -10,6 +10,7 @@ #include "RenderPlugin.h" #include #include +#include namespace EMStudio diff --git a/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/RenderUpdateCallback.cpp b/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/RenderUpdateCallback.cpp index 49bb5509b6..2024746971 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/RenderUpdateCallback.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/RenderUpdateCallback.cpp @@ -13,6 +13,7 @@ #include #include "RenderWidget.h" #include "RenderViewWidget.h" +#include namespace EMStudio diff --git a/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/Plugins/RenderPlugins/Source/OpenGLRender/GLWidget.cpp b/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/Plugins/RenderPlugins/Source/OpenGLRender/GLWidget.cpp index c6cab07a44..eefac45a3b 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/Plugins/RenderPlugins/Source/OpenGLRender/GLWidget.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/Plugins/RenderPlugins/Source/OpenGLRender/GLWidget.cpp @@ -15,8 +15,10 @@ #include #include #include -#include "../../../../EMStudioSDK/Source/RenderPlugin/RenderViewWidget.h" +#include +#include +#include namespace EMStudio { diff --git a/Gems/GraphModel/Code/Include/GraphModel/Integration/FloatDataInterface.h b/Gems/GraphModel/Code/Include/GraphModel/Integration/FloatDataInterface.h index 66c0f57fe4..8aefe5baf0 100644 --- a/Gems/GraphModel/Code/Include/GraphModel/Integration/FloatDataInterface.h +++ b/Gems/GraphModel/Code/Include/GraphModel/Integration/FloatDataInterface.h @@ -8,6 +8,9 @@ #pragma once +// Graph Canvas +#include + // Graph Model #include @@ -36,3 +39,4 @@ namespace GraphModelIntegration AZStd::weak_ptr m_slot; }; } + diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Core/GetVariable.cpp b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Core/GetVariable.cpp index f88fb03726..e77d1abeb6 100644 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Core/GetVariable.cpp +++ b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Core/GetVariable.cpp @@ -12,6 +12,7 @@ #include #include #include +#include namespace ScriptCanvas {