From cbaf45084e47e4bd1c29e96ac4959431b12771e7 Mon Sep 17 00:00:00 2001 From: captivator <84224501+qaptivator@users.noreply.github.com> Date: Fri, 17 Apr 2026 15:12:22 +0300 Subject: [PATCH] fix world size uninitialized memory and UI refresh signal Signed-off-by: captivator <84224501+qaptivator@users.noreply.github.com> --- launcher/minecraft/WorldList.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/launcher/minecraft/WorldList.cpp b/launcher/minecraft/WorldList.cpp index 4aa0f7532..ca8ac1aa8 100644 --- a/launcher/minecraft/WorldList.cpp +++ b/launcher/minecraft/WorldList.cpp @@ -157,7 +157,8 @@ bool WorldList::resetIcon(int row) return false; World& m = m_worlds[row]; if (m.resetIcon()) { - emit dataChanged(index(row), index(row), { WorldList::IconFileRole }); + QModelIndex modelIndex = index(row, NameColumn); + emit dataChanged(modelIndex, modelIndex, { WorldList::IconFileRole }); return true; } return false; @@ -426,7 +427,7 @@ void WorldList::loadWorldsAsync() m_worlds[row].setSize(size); // Notify views - QModelIndex modelIndex = index(row); + QModelIndex modelIndex = index(row, SizeColumn); emit dataChanged(modelIndex, modelIndex, { SizeRole }); } },