diff --git a/Makefile b/Makefile index 79a6a6b331fe6..c2390e04882ba 100644 --- a/Makefile +++ b/Makefile @@ -956,6 +956,7 @@ SOURCES += $(THIRD_PARTY_SOURCES) IMGUI_SOURCES = $(IMGUI_DIR)/imgui.cpp $(IMGUI_DIR)/imgui_demo.cpp $(IMGUI_DIR)/imgui_draw.cpp $(IMGUI_DIR)/imgui_tables.cpp $(IMGUI_DIR)/imgui_widgets.cpp ifeq ($(SDL), 1) + OTHERS += -DIMGUI_DISABLE_OBSOLETE_KEYIO IMGUI_SOURCES += $(IMGUI_DIR)/imgui_impl_sdl2.cpp $(IMGUI_DIR)/imgui_impl_sdlrenderer2.cpp else IMGUI_SOURCES += $(IMTUI_DIR)/imtui-impl-ncurses.cpp $(IMTUI_DIR)/imtui-impl-text.cpp diff --git a/msvc-full-features/Cataclysm-common.props b/msvc-full-features/Cataclysm-common.props index 832e0c55d5e3d..abf9ac68d6c9c 100644 --- a/msvc-full-features/Cataclysm-common.props +++ b/msvc-full-features/Cataclysm-common.props @@ -55,7 +55,7 @@ Use $(MSBuildThisFileDirectory)..\pch\main-pch.hpp 4661;4819;4146;26495;26444;26451;4068;6319;6237 - _SCL_SECURE_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;WIN32_LEAN_AND_MEAN;LOCALIZE;USE_VCPKG;%(PreprocessorDefinitions) + _SCL_SECURE_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;WIN32_LEAN_AND_MEAN;LOCALIZE;USE_VCPKG;IMGUI_DISABLE_OBSOLETE_KEYIO;%(PreprocessorDefinitions) true $(MSBuildThisFileDirectory)..\pch\main-pch.hpp diff --git a/src/third-party/CMakeLists.txt b/src/third-party/CMakeLists.txt index 47f253d903202..f44d9f01880ce 100644 --- a/src/third-party/CMakeLists.txt +++ b/src/third-party/CMakeLists.txt @@ -102,6 +102,9 @@ if (TILES) PRIVATE -w ) + + add_definitions(-DIMGUI_DISABLE_OBSOLETE_KEYIO) + if (NOT DYNAMIC_LINKING) target_link_libraries(imgui PUBLIC SDL2::SDL2-static