From 160b035c4d5b88516cb4d1f4e26ec2e2e0262bcc Mon Sep 17 00:00:00 2001 From: Tulir Asokan Date: Sat, 15 Jun 2019 17:04:08 +0300 Subject: Unbreak more things --- ui/room-list.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'ui/room-list.go') diff --git a/ui/room-list.go b/ui/room-list.go index f0a9703..53337b6 100644 --- a/ui/room-list.go +++ b/ui/room-list.go @@ -423,8 +423,10 @@ func (list *RoomList) OnMouseEvent(event mauview.MouseEvent) bool { switch event.Buttons() { case tcell.WheelUp: list.AddScrollOffset(-WheelScrollOffsetDiff) + return true case tcell.WheelDown: list.AddScrollOffset(WheelScrollOffsetDiff) + return true case tcell.Button1: x, y := event.Position() return list.clickRoom(y, x, event.Modifiers() == tcell.ModCtrl) @@ -486,7 +488,8 @@ func (list *RoomList) clickRoom(line, column int, mod bool) bool { if trl.maxShown < 10 { trl.maxShown = 10 } - break + list.RUnlock() + return true } } // Tag footer -- cgit v1.2.3