From bbe3fcfdd9416c52317879151464c793326f14cf Mon Sep 17 00:00:00 2001 From: karlberg Date: Tue, 4 May 2021 08:49:35 -0700 Subject: [PATCH] Cleans up some debug code --- .../AzCore/AzCore/Console/LoggerSystemComponent.cpp | 1 - .../Entity/EditorEntityContextComponent.cpp | 5 ----- .../Entity/EditorEntityContextComponent.h | 2 -- .../Tests/Visibility/EditorVisibilityTests.cpp | 2 +- Gems/ImGui/External/ImGui/v1.82/imgui/imgui.cpp | 8 ++++---- 5 files changed, 5 insertions(+), 13 deletions(-) diff --git a/Code/Framework/AzCore/AzCore/Console/LoggerSystemComponent.cpp b/Code/Framework/AzCore/AzCore/Console/LoggerSystemComponent.cpp index b19d4c7071..de29edc3b0 100644 --- a/Code/Framework/AzCore/AzCore/Console/LoggerSystemComponent.cpp +++ b/Code/Framework/AzCore/AzCore/Console/LoggerSystemComponent.cpp @@ -126,7 +126,6 @@ namespace AZ char buffer[MaxLogBufferSize]; const AZStd::size_t length = azvsnprintf(buffer, MaxLogBufferSize, format, args); - //buffer[AZStd::min(length, MaxLogBufferSize - 2)] = '\n'; buffer[AZStd::min(length + 1, MaxLogBufferSize - 1)] = '\0'; switch (level) diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/EditorEntityContextComponent.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/EditorEntityContextComponent.cpp index 5237e7adf6..041a0f4195 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/EditorEntityContextComponent.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/EditorEntityContextComponent.cpp @@ -189,9 +189,6 @@ namespace AzToolsFramework SliceEditorEntityOwnershipServiceNotificationBus::Handler::BusConnect(); EditorLegacyGameModeNotificationBus::Handler::BusConnect(); - - //m_entityVisibilityBoundsUnionSystem.Connect(); - } //========================================================================= @@ -199,8 +196,6 @@ namespace AzToolsFramework //========================================================================= void EditorEntityContextComponent::Deactivate() { - //m_entityVisibilityBoundsUnionSystem.Disconnect(); - EditorLegacyGameModeNotificationBus::Handler::BusDisconnect(); SliceEditorEntityOwnershipServiceNotificationBus::Handler::BusDisconnect(); diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/EditorEntityContextComponent.h b/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/EditorEntityContextComponent.h index d59792752b..92c7f84703 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/EditorEntityContextComponent.h +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/EditorEntityContextComponent.h @@ -189,8 +189,6 @@ namespace AzToolsFramework //! EditorEntityContextRequestBus::Events::AddRequiredComponents() AZ::ComponentTypeList m_requiredEditorComponentTypes; - //! Edit time visibility management integrating entities with the IVisibilitySystem. - //AzFramework::EntityVisibilityBoundsUnionSystem m_entityVisibilityBoundsUnionSystem; bool m_isLegacySliceService; UndoSystem::UndoCacheInterface* m_undoCacheInterface = nullptr; diff --git a/Code/Framework/AzToolsFramework/Tests/Visibility/EditorVisibilityTests.cpp b/Code/Framework/AzToolsFramework/Tests/Visibility/EditorVisibilityTests.cpp index 39b2d069e6..a7aeee5660 100644 --- a/Code/Framework/AzToolsFramework/Tests/Visibility/EditorVisibilityTests.cpp +++ b/Code/Framework/AzToolsFramework/Tests/Visibility/EditorVisibilityTests.cpp @@ -9,7 +9,7 @@ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * */ -#pragma optimize("", off) + #include #include #include diff --git a/Gems/ImGui/External/ImGui/v1.82/imgui/imgui.cpp b/Gems/ImGui/External/ImGui/v1.82/imgui/imgui.cpp index c386766eef..2555d1a6af 100644 --- a/Gems/ImGui/External/ImGui/v1.82/imgui/imgui.cpp +++ b/Gems/ImGui/External/ImGui/v1.82/imgui/imgui.cpp @@ -759,7 +759,7 @@ CODE //------------------------------------------------------------------------- // [SECTION] INCLUDES //------------------------------------------------------------------------- -#pragma optimize("", off) + #if defined(_MSC_VER) && !defined(_CRT_SECURE_NO_WARNINGS) #define _CRT_SECURE_NO_WARNINGS #endif @@ -7117,9 +7117,9 @@ static void ImGui::ErrorCheckEndFrameSanityChecks() // send key release events mid-frame. This would normally trigger this assertion and lead to sheared inputs. // We silently accommodate for this case by ignoring/ the case where all io.KeyXXX modifiers were released (aka key_mod_flags == 0), // while still correctly asserting on mid-frame key press events. - //const ImGuiKeyModFlags key_mod_flags = GetMergedKeyModFlags(); - //IM_ASSERT((key_mod_flags == 0 || g.IO.KeyMods == key_mod_flags) && "Mismatching io.KeyCtrl/io.KeyShift/io.KeyAlt/io.KeySuper vs io.KeyMods"); - //IM_UNUSED(key_mod_flags); + const ImGuiKeyModFlags key_mod_flags = GetMergedKeyModFlags(); + IM_ASSERT((key_mod_flags == 0 || g.IO.KeyMods == key_mod_flags) && "Mismatching io.KeyCtrl/io.KeyShift/io.KeyAlt/io.KeySuper vs io.KeyMods"); + IM_UNUSED(key_mod_flags); // Recover from errors //ErrorCheckEndFrameRecover();