diff options
author | Joe <rbo@gmx.us> | 2024-01-10 20:20:20 +0100 |
---|---|---|
committer | Joe <rbo@gmx.us> | 2024-01-10 20:20:20 +0100 |
commit | 2bcf613e91cfaa214cd6e1847df43e94358c3497 (patch) | |
tree | 7cf19737418516c3c00d6c17fcd70b7a64a36ac6 /i_ui.go | |
parent | delete dir next (diff) | |
download | hardflip-2bcf613e91cfaa214cd6e1847df43e94358c3497.tar.gz hardflip-2bcf613e91cfaa214cd6e1847df43e94358c3497.tar.bz2 hardflip-2bcf613e91cfaa214cd6e1847df43e94358c3497.tar.xz hardflip-2bcf613e91cfaa214cd6e1847df43e94358c3497.tar.zst hardflip-2bcf613e91cfaa214cd6e1847df43e94358c3497.zip |
cool box bro
Diffstat (limited to 'i_ui.go')
-rw-r--r-- | i_ui.go | 13 |
1 files changed, 9 insertions, 4 deletions
@@ -60,6 +60,7 @@ import ( type HardUI struct { s tcell.Screen mode uint8 + // HACK: fuck sel_max sel_max int def_style tcell.Style dir_style tcell.Style @@ -160,12 +161,16 @@ func i_draw_zhosts_box(ui HardUI) { } func i_draw_delete_box(ui HardUI, item *ItemsNode) { + var text string + var file string if item.is_dir() == true { - return + text = "Really delete this directory and all subsequent files?" + file = item.Dirs.path() + } else { + host := item.Host + text = "Really delete this host?" + file = host.Parent.path() + host.Filename } - host := item.Host - text := "Really delete this host?" - file := host.Parent.path() + host.Filename max_len := len(text) if max_len < len(file) { |