mirror of
https://github.com/spice2x/spice2x.github.io.git
synced 2026-08-01 22:30:42 -07:00
imgui: update to v1.91.4, make various fixes to overlay (#286)
## Link to GitHub Issue, if one exists
n/a
## Description of change
Update ImGui to `v1.91.4`. We can't update to `v1.91.5` or newer just
yet because impl_spice depends on the old IO model of ImGui which got
removed in `v1.91.5`.
We also can't update the DX9 renderer right now, because at some point
overlay breaks in TDJ (and only in TDJ...)
Enable the new debug logging functionality in ImGui. Add a button in
overlay to toggle debug log window.
Fix some minor bugs spotted by the new ImGui debug log: mismatched API
calls, font loading issues.
## Compiling
👍
## Testing
In progress.
This commit is contained in:
@@ -17,7 +17,9 @@
|
||||
!defined(IMGUI_DISABLE_DEFAULT_ALLOCATORS) || \
|
||||
!defined(IMGUI_USE_BGRA_PACKED_COLOR) || \
|
||||
!defined(IMGUI_HAS_VIEWPORT) || \
|
||||
!defined(IMGUI_HAS_DOCK)
|
||||
!defined(IMGUI_HAS_DOCK) || \
|
||||
!defined(IMGUI_DISABLE_DEMO_WINDOWS) || \
|
||||
defined(IMGUI_DISABLE_DEBUG_TOOLS)
|
||||
#error "fix imconfig.h after updating imgui version"
|
||||
#endif
|
||||
|
||||
@@ -51,6 +53,7 @@ bool ImGui_ImplSpice_Init(HWND hWnd) {
|
||||
io.BackendFlags |= ImGuiBackendFlags_HasMouseCursors;
|
||||
io.BackendFlags |= ImGuiBackendFlags_HasSetMousePos;
|
||||
io.BackendPlatformName = "imgui_impl_spice";
|
||||
io.ConfigErrorRecoveryEnableTooltip = true;
|
||||
|
||||
// keyboard mapping
|
||||
io.KeyMap[ImGuiKey_Tab] = VK_TAB;
|
||||
@@ -68,7 +71,7 @@ bool ImGui_ImplSpice_Init(HWND hWnd) {
|
||||
io.KeyMap[ImGuiKey_Space] = VK_SPACE;
|
||||
io.KeyMap[ImGuiKey_Enter] = VK_RETURN;
|
||||
io.KeyMap[ImGuiKey_Escape] = VK_ESCAPE;
|
||||
io.KeyMap[ImGuiKey_KeyPadEnter] = VK_RETURN;
|
||||
io.KeyMap[ImGuiKey_KeypadEnter] = VK_RETURN;
|
||||
io.KeyMap[ImGuiKey_A] = 'A';
|
||||
io.KeyMap[ImGuiKey_C] = 'C';
|
||||
io.KeyMap[ImGuiKey_V] = 'V';
|
||||
|
||||
Reference in New Issue
Block a user