diff options
author | Joe <rbo@gmx.us> | 2024-01-23 20:20:20 +0100 |
---|---|---|
committer | Joe <rbo@gmx.us> | 2024-01-23 20:20:20 +0100 |
commit | d2c0fdf3e0166f7ba2b82df74a2b5d858c00178e (patch) | |
tree | 3b18e17799f832ee0f072eae6f21df27b4e21e0d /src/i_events.go | |
parent | bench time (diff) | |
download | hardflip-d2c0fdf3e0166f7ba2b82df74a2b5d858c00178e.tar.gz hardflip-d2c0fdf3e0166f7ba2b82df74a2b5d858c00178e.tar.bz2 hardflip-d2c0fdf3e0166f7ba2b82df74a2b5d858c00178e.tar.xz hardflip-d2c0fdf3e0166f7ba2b82df74a2b5d858c00178e.tar.zst hardflip-d2c0fdf3e0166f7ba2b82df74a2b5d858c00178e.zip |
good loading errmsg
Diffstat (limited to 'src/i_events.go')
-rw-r--r-- | src/i_events.go | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/i_events.go b/src/i_events.go index 427f9c1..7ca1511 100644 --- a/src/i_events.go +++ b/src/i_events.go @@ -168,7 +168,8 @@ func i_fold_dir(data *HardData, item *ItemsNode) { func i_reload_data(data *HardData) { data.data_dir = c_get_data_dir() g_load_count = -1 - data.ldirs, data.litems, data.load_err = i_load_ui(data.data_dir, data.opts, &data.ui) + data.ldirs, data.litems, data.load_err = i_load_ui(data.data_dir, data.opts, + &data.ui) // FIX: must input to start reloading for some reason data.folds = make(map[*DirsNode]*ItemsList) } @@ -325,6 +326,7 @@ func i_events(data *HardData) { i_unfold_dir(data, data.litems.curr) } } else if event.Key() == tcell.KeyCtrlR { + event = nil i_reload_data(data) } i_list_follow_cursor(data.litems, ui) @@ -341,7 +343,7 @@ func i_events(data *HardData) { } } case ERROR_MODE: - if event.Rune() == 'q' || + if event.Rune() != 0 || event.Key() == tcell.KeyEnter { ui.mode = NORMAL_MODE data.load_err = nil |