fix: handle null returnState in archive loading process

This commit is contained in:
Radek Davidek 2026-07-17 13:45:41 +02:00
parent 5f6b44fb4a
commit 2735055a58

View File

@ -3318,9 +3318,15 @@ public class FilePanelTab extends JPanel {
deleteTempDirRecursively(currentArchiveTempDir); deleteTempDirRecursively(currentArchiveTempDir);
clearOpenedArchiveSession(); clearOpenedArchiveSession();
loadDirectory(parent, false, true, () -> { loadDirectory(parent, false, true, () -> {
if (returnState != null) {
restoreReturnState(returnState, true); restoreReturnState(returnState, true);
} else {
selectItemByName(archiveName);
}
SwingUtilities.invokeLater(() -> { SwingUtilities.invokeLater(() -> {
if (returnState != null) {
restoreReturnState(returnState, true); restoreReturnState(returnState, true);
}
clearArchiveReturnState(); clearArchiveReturnState();
}); });
}); });