summaryrefslogtreecommitdiffstats
path: root/tui/mouse.go
diff options
context:
space:
mode:
authorDaniel Milde <daniel@milde.cz>2023-02-03 10:54:37 +0100
committerDaniel Milde <daniel@milde.cz>2023-02-03 11:03:13 +0100
commit8bdce9a33d2e7e7bbe127dcdceee78237070c19f (patch)
tree33217229851d3df9a06ac0c86a621bc4bee02c2e /tui/mouse.go
parent10c8ae1824b89fd6b62a286df44b5e9bc72ef2f6 (diff)
fix: ignore mouse events when modal is opened
Diffstat (limited to 'tui/mouse.go')
-rw-r--r--tui/mouse.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/tui/mouse.go b/tui/mouse.go
index 18ef8b3..c8aa95c 100644
--- a/tui/mouse.go
+++ b/tui/mouse.go
@@ -11,6 +11,14 @@ func (ui *UI) onMouse(event *tcell.EventMouse, action tview.MouseAction) (*tcell
return nil, action
}
+ if ui.pages.HasPage("confirm") ||
+ ui.pages.HasPage("progress") ||
+ ui.pages.HasPage("deleting") ||
+ ui.pages.HasPage("emptying") ||
+ ui.pages.HasPage("help") {
+ return nil, action
+ }
+
switch action {
case tview.MouseLeftDoubleClick:
row, column := ui.table.GetSelection()