[nostalgia/core/studio] Change Subsheet Editor button position
All checks were successful
Build / build (push) Successful in 2m21s
All checks were successful
Build / build (push) Successful in 2m21s
This commit is contained in:
parent
7ba66787f8
commit
5848bc8eb7
@ -499,14 +499,16 @@ void TileSheetEditorImGui::SubSheetEditor::draw() noexcept {
|
|||||||
}
|
}
|
||||||
ImGui::OpenPopup(popupName);
|
ImGui::OpenPopup(popupName);
|
||||||
auto const modSize = m_cols > 0;
|
auto const modSize = m_cols > 0;
|
||||||
|
auto const popupWidth = 235.f;
|
||||||
auto const popupHeight = modSize ? 125.f : 80.f;
|
auto const popupHeight = modSize ? 125.f : 80.f;
|
||||||
ImGui::SetNextWindowSize(ImVec2(235, popupHeight));
|
ImGui::SetNextWindowSize(ImVec2(popupWidth, popupHeight));
|
||||||
if (ImGui::BeginPopupModal(popupName, &m_show, modalFlags)) {
|
if (ImGui::BeginPopupModal(popupName, &m_show, modalFlags)) {
|
||||||
ImGui::InputText("Name", m_name.data(), m_name.cap());
|
ImGui::InputText("Name", m_name.data(), m_name.cap());
|
||||||
if (modSize) {
|
if (modSize) {
|
||||||
ImGui::InputInt("Columns", &m_cols);
|
ImGui::InputInt("Columns", &m_cols);
|
||||||
ImGui::InputInt("Rows", &m_rows);
|
ImGui::InputInt("Rows", &m_rows);
|
||||||
}
|
}
|
||||||
|
ImGui::SetCursorPosX(popupWidth - 116);
|
||||||
if (ImGui::Button("OK", ImVec2{50, 20})) {
|
if (ImGui::Button("OK", ImVec2{50, 20})) {
|
||||||
ImGui::CloseCurrentPopup();
|
ImGui::CloseCurrentPopup();
|
||||||
m_show = false;
|
m_show = false;
|
||||||
|
Loading…
Reference in New Issue
Block a user