aboutsummaryrefslogtreecommitdiffstats
path: root/i_ui.go
diff options
context:
space:
mode:
authorJoe <rbo@gmx.us>2024-01-09 20:20:20 +0100
committerJoe <rbo@gmx.us>2024-01-09 20:20:20 +0100
commit6f866cf8feb9d5c7707e337c6edb2335c1fa16d8 (patch)
treef471d53f293ad2991d9b241721323eb277a028d7 /i_ui.go
parentclean (diff)
downloadhardflip-6f866cf8feb9d5c7707e337c6edb2335c1fa16d8.tar.gz
hardflip-6f866cf8feb9d5c7707e337c6edb2335c1fa16d8.tar.bz2
hardflip-6f866cf8feb9d5c7707e337c6edb2335c1fa16d8.tar.xz
hardflip-6f866cf8feb9d5c7707e337c6edb2335c1fa16d8.tar.zst
hardflip-6f866cf8feb9d5c7707e337c6edb2335c1fa16d8.zip
folding visually
Diffstat (limited to '')
-rw-r--r--i_ui.go11
1 files changed, 7 insertions, 4 deletions
diff --git a/i_ui.go b/i_ui.go
index 87c9483..b4ffc20 100644
--- a/i_ui.go
+++ b/i_ui.go
@@ -43,7 +43,7 @@
* POSSIBILITY OF SUCH DAMAGE.
*
* hardflip: src/i_ui.go
- * Tue Jan 09 11:49:48 2024
+ * Tue Jan 09 12:00:46 2024
* Joe
*
* interfacing with the user
@@ -283,20 +283,23 @@ func i_host_panel(ui HardUI, icons bool, litems *ItemsList) {
line := 1
ptr := litems.draw_start
for ptr = ptr; ptr != nil && line < ui.dim[H] - 2; ptr = ptr.next {
- if ptr.is_dir() == false {
+ if ptr.is_dir() == false &&
+ ptr.Host.folded_parents() == false &&
+ ptr.Host != nil {
i_host_panel_host(ui,
icons,
ptr.Host.Parent.Depth,
ptr.Host,
litems.curr.Host,
line)
- } else {
+ line++
+ } else if ptr.Dirs != nil && ptr.Dirs.folded_parents() == false {
i_host_panel_dirs(ui, icons,
ptr.Dirs,
litems.curr.Dirs,
line)
+ line++
}
- line++
}
if ui.sel_max != 0 {
i_draw_text(ui.s,