summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKiritoDv <kiritodev01@gmail.com>2025-01-15 13:12:00 -0600
committerKiritoDv <kiritodev01@gmail.com>2025-01-15 13:12:00 -0600
commit5aac47e2fafb99678fc21e7839ec0e9cc7d65f70 (patch)
treea7b2e6c68b9550f77220b0cc59edffe3562de33c
parent223280a84ed69b3606d59f24f21ae0a2470110fd (diff)
Updated LUS
m---------libultraship0
-rw-r--r--src/port/Engine.cpp13
-rw-r--r--src/port/ui/UIWidgets.cpp2
3 files changed, 11 insertions, 4 deletions
diff --git a/libultraship b/libultraship
-Subproject 3e46fe77a4581a84f9c0edfab9c3a69a5320fe0
+Subproject 31df12cdb7b877f4f0790dcc216a2c9d3823d58
diff --git a/src/port/Engine.cpp b/src/port/Engine.cpp
index a764d61f..9d577583 100644
--- a/src/port/Engine.cpp
+++ b/src/port/Engine.cpp
@@ -218,7 +218,6 @@ void GameEngine::StartFrame() const {
default:
break;
}
- this->context->GetWindow()->StartFrame();
}
#if 0
@@ -329,9 +328,17 @@ void GameEngine::AudioExit() {
}
void GameEngine::RunCommands(Gfx* Commands, const std::vector<std::unordered_map<Mtx*, MtxF>>& mtx_replacements) {
+ auto wnd = std::dynamic_pointer_cast<Fast::Fast3dWindow>(Ship::Context::GetInstance()->GetWindow());
+
+ if (wnd == nullptr) {
+ return;
+ }
+
+ // Process window events for resize, mouse, keyboard events
+ wnd->HandleEvents();
+
for (const auto& m : mtx_replacements) {
- gfx_run(Commands, m);
- gfx_end_frame();
+ wnd->DrawAndRunGraphicsCommands(Commands, m);
}
bool curAltAssets = CVarGetInteger("gEnhancements.Mods.AlternateAssets", 0);
diff --git a/src/port/ui/UIWidgets.cpp b/src/port/ui/UIWidgets.cpp
index d89b697a..3bac9f3a 100644
--- a/src/port/ui/UIWidgets.cpp
+++ b/src/port/ui/UIWidgets.cpp
@@ -156,7 +156,7 @@ namespace UIWidgets {
ImGui::RenderFrame(check_bb.Min, check_bb.Max, ImGui::GetColorU32((held && hovered) ? ImGuiCol_FrameBgActive : hovered ? ImGuiCol_FrameBgHovered : ImGuiCol_FrameBg), true, style.FrameRounding);
ImU32 check_col = ImGui::GetColorU32(ImGuiCol_CheckMark);
ImU32 cross_col = ImGui::GetColorU32(ImVec4(0.50f, 0.50f, 0.50f, 1.00f));
- bool mixed_value = (g.LastItemData.InFlags & ImGuiItemFlags_MixedValue) != 0;
+ bool mixed_value = (g.LastItemData.ItemFlags & ImGuiItemFlags_MixedValue) != 0;
if (mixed_value) {
// Undocumented tristate/mixed/indeterminate checkbox (#2644)
// This may seem awkwardly designed because the aim is to make ImGuiItemFlags_MixedValue supported by all widgets (not just checkbox)