From 9c97f21e43a35d5c567e34c2b63d74ee2bfe6879 Mon Sep 17 00:00:00 2001
From: Ramen2X <rmn@legoisland.org>
Date: Fri, 13 Dec 2024 14:20:39 -0500
Subject: [PATCH] app: properly clear screen on new file

---
 app/mainwindow.cpp | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/app/mainwindow.cpp b/app/mainwindow.cpp
index a71d263..352a1cb 100644
--- a/app/mainwindow.cpp
+++ b/app/mainwindow.cpp
@@ -303,6 +303,8 @@ void MainWindow::TrimOffDirectory(QString& s)
 
 void MainWindow::NewFile()
 {
+  tree_->clearSelection();
+  SetPanel(panel_blank_, nullptr);
   model_.SetCore(nullptr);
   interleaf_.Clear();
   model_.SetCore(&interleaf_);