diff options
author | Joe <rbo@gmx.us> | 2023-12-20 20:20:20 +0100 |
---|---|---|
committer | Joe <rbo@gmx.us> | 2023-12-20 20:20:20 +0100 |
commit | 52498606aa3ce19844563f01a6c099a2a949bdf0 (patch) | |
tree | 721d5ea31d4acafccbd7faf3927e5eed5672196a | |
parent | wip (diff) | |
download | hardflip-52498606aa3ce19844563f01a6c099a2a949bdf0.tar.gz hardflip-52498606aa3ce19844563f01a6c099a2a949bdf0.tar.bz2 hardflip-52498606aa3ce19844563f01a6c099a2a949bdf0.tar.xz hardflip-52498606aa3ce19844563f01a6c099a2a949bdf0.tar.zst hardflip-52498606aa3ce19844563f01a6c099a2a949bdf0.zip |
gG
-rw-r--r-- | i_events.go | 8 | ||||
-rw-r--r-- | i_ui.go | 4 |
2 files changed, 9 insertions, 3 deletions
diff --git a/i_events.go b/i_events.go index 524b612..74dbe06 100644 --- a/i_events.go +++ b/i_events.go @@ -39,7 +39,7 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * * hardflip: src/i_events.go - * Wed Dec 20 12:19:56 2023 + * Wed Dec 20 16:17:19 2023 * Joe * * the hosts linked list @@ -98,6 +98,12 @@ func i_events(data *Data, *sel -= 1 } } + if event.Rune() == 'g' { + *sel = 0 + } + if event.Rune() == 'G' { + *sel = *sel_max - 1 + } if event.Rune() == 'D' { i_delete_selected(data, sel) i_reload_data(data, sel, sel_max) @@ -384,8 +384,8 @@ func i_ui(data *Data) { } data.s.Show() i_events(data, &sel, &sel_max, &term_size) - if int(sel) > term_size[H] - 6 { - data.list_start += 1 + if int(sel) > term_size[H] - 4 { + // data.list_start = data.list } } } |