From 58b0254ff5d48931c9d54756f2f3e89c0e62494d Mon Sep 17 00:00:00 2001 From: Gary Talent Date: Sat, 11 Jan 2025 16:26:17 -0600 Subject: [PATCH] [jasper/world/studio] Cleanup --- .../world/src/studio/worldeditor/worldeditor-imgui.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/jasper/modules/world/src/studio/worldeditor/worldeditor-imgui.cpp b/src/jasper/modules/world/src/studio/worldeditor/worldeditor-imgui.cpp index be1d207..6046af8 100644 --- a/src/jasper/modules/world/src/studio/worldeditor/worldeditor-imgui.cpp +++ b/src/jasper/modules/world/src/studio/worldeditor/worldeditor-imgui.cpp @@ -22,7 +22,7 @@ namespace jasper::world { namespace ig = studio::ig; -constexpr auto SqrBtnSize = ImVec2(ig::BtnSz.y, ig::BtnSz.y); +constexpr auto SqrBtnSize = ImVec2{ig::BtnSz.y, ig::BtnSz.y}; struct WorldEditorConfig { static constexpr auto TypeName = "net.drinkingtea.jasper.world.studio.WorldEditorConfig"; @@ -91,7 +91,7 @@ void WorldEditorImGui::draw(studio::StudioContext&) noexcept { auto const paneSize = ImGui::GetContentRegionAvail(); constexpr auto resourcesWidth = 300.f; { - ig::ChildStackItem const worldView{"WorldView", ImVec2(paneSize.x - resourcesWidth, 0)}; + ig::ChildStackItem const worldView{"WorldView", {paneSize.x - resourcesWidth, 0}}; drawWorldView(); } ImGui::SameLine(); @@ -302,8 +302,8 @@ void WorldEditorImGui::drawWorldView() noexcept { ImGui::Image( ig::toImTextureID(fb.color.id), paneSize, - ImVec2(0, 1), - ImVec2(xScale, 1 - yScale)); + {0, 1}, + {xScale, 1 - yScale}); std::ignore = ig::dragDropTarget([this, fbPaneScale] { return handleDrop(fbPaneScale); });