[nostalgia/core/studio] Fix subsheet editor to allocate correct number of pixels
This commit is contained in:
@@ -102,7 +102,6 @@ void TileSheetEditorImGui::draw(core::Context*) noexcept {
|
||||
}
|
||||
ImGui::EndChild();
|
||||
m_subsheetEditor.draw();
|
||||
ImGui::ShowDemoWindow();
|
||||
}
|
||||
|
||||
void TileSheetEditorImGui::drawSubsheetSelector(TileSheet::SubSheet *subsheet, TileSheet::SubSheetIdx *path) noexcept {
|
||||
@@ -241,10 +240,11 @@ ox::Error TileSheetEditorImGui::markUnsavedChanges(int) noexcept {
|
||||
void TileSheetEditorImGui::SubSheetEditor::draw() noexcept {
|
||||
constexpr auto modalFlags = ImGuiWindowFlags_NoCollapse | ImGuiWindowFlags_NoMove | ImGuiWindowFlags_NoResize;
|
||||
constexpr auto popupName = "Edit SubSheet";
|
||||
if (m_show) {
|
||||
ImGui::OpenPopup(popupName);
|
||||
ImGui::SetNextWindowSize(ImVec2(235, 125));
|
||||
if (!m_show) {
|
||||
return;
|
||||
}
|
||||
ImGui::OpenPopup(popupName);
|
||||
ImGui::SetNextWindowSize(ImVec2(235, 125));
|
||||
if (ImGui::BeginPopupModal(popupName, &m_show, modalFlags)) {
|
||||
ImGui::InputText("Name", m_name.data(), m_name.cap());
|
||||
if (m_cols != -1) {
|
||||
|
||||
Reference in New Issue
Block a user