mirror of
https://github.com/zyedidia/micro.git
synced 2026-02-07 23:50:18 +09: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:
@@ -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
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user