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