From 934145980bc4c16b81d5c8e603fba36bfe07274c Mon Sep 17 00:00:00 2001 From: pingu Date: Mon, 16 Oct 2023 16:14:18 +0200 Subject: [PATCH] =?UTF-8?q?=CA=98=E2=80=BF=CA=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/Main.hs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/app/Main.hs b/app/Main.hs index 13565b2..73e3921 100644 --- a/app/Main.hs +++ b/app/Main.hs @@ -93,7 +93,12 @@ pathWidget (f, s) = str (show f) <+> padLeft Max (str (show s)) sizeDir :: AppS -> IO AppS sizeDir s = do subFiles <- getSizeSubpaths $ _appCWD s - pure $ s {_appSubFiles = subFiles} + pure $ + s { + _appCursor = 0 + , _appFocus = map fst subFiles !? 0 + , _appSubFiles = subFiles + } changeDir :: AppS -> IO AppS changeDir so