mirror of
https://github.com/Hopiu/micro.git
synced 2026-03-28 03:40:24 +00:00
Fix non-working mouse wheel scrolling on the top line of the screen
Scroll the tab bar only if there actually is the tab bar, otherwise propagate the mouse wheel event to the bufpane.
This commit is contained in:
parent
602acff42f
commit
badaba66f3
1 changed files with 2 additions and 2 deletions
|
|
@ -132,12 +132,12 @@ func (t *TabList) HandleEvent(event tcell.Event) {
|
|||
return
|
||||
}
|
||||
case tcell.WheelUp:
|
||||
if my == t.Y {
|
||||
if my == t.Y && len(t.List) > 1 {
|
||||
t.Scroll(4)
|
||||
return
|
||||
}
|
||||
case tcell.WheelDown:
|
||||
if my == t.Y {
|
||||
if my == t.Y && len(t.List) > 1 {
|
||||
t.Scroll(-4)
|
||||
return
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue