build: Make ImHex fully compile with warnings enabled in MSVC

This commit is contained in:
WerWolv
2025-02-10 09:42:35 +01:00
parent 3a7578879f
commit e1580e51cf
26 changed files with 70 additions and 43 deletions

View File

@@ -8,6 +8,9 @@ else()
set(BUILD_TESTING OFF CACHE BOOL "" FORCE)
add_subdirectory(${THIRD_PARTY_LIBS_FOLDER}/edlib ${CMAKE_CURRENT_BINARY_DIR}/edlib EXCLUDE_FROM_ALL)
enableUnityBuild(edlib)
if (MSVC)
target_compile_options(edlib PRIVATE /wd4244)
endif ()
endif()
add_imhex_plugin(

View File

@@ -204,7 +204,7 @@ namespace hex::plugin::diffing {
const auto availableSize = ImGui::GetContentRegionAvail();
auto diffingColumnSize = availableSize;
diffingColumnSize.y *= 3.5 / 5.0;
diffingColumnSize.y *= 3.5F / 5.0F;
diffingColumnSize.y -= ImGui::GetTextLineHeightWithSpacing();
diffingColumnSize.y += height;