1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-07-15 01:34:26 +02:00

Bump gocui

This commit is contained in:
Stefan Haller
2025-02-10 13:40:22 +01:00
parent 3012306ac3
commit 46ebfbbe87
5 changed files with 37 additions and 4 deletions

View File

@ -155,6 +155,8 @@ type gocuiEventType uint8
// The 'MouseX' and 'MouseY' fields are valid if 'Type' is 'eventMouse'.
// The 'Width' and 'Height' fields are valid if 'Type' is 'eventResize'.
// The 'Focused' field is valid if 'Type' is 'eventFocus'.
// The 'Start' field is valid if 'Type' is 'eventPaste'. It is true for the
// beginning of a paste operation, false for the end.
// The 'Err' field is valid if 'Type' is 'eventError'.
type GocuiEvent struct {
Type gocuiEventType
@ -167,6 +169,7 @@ type GocuiEvent struct {
MouseX int
MouseY int
Focused bool
Start bool
N int
}
@ -178,6 +181,7 @@ const (
eventMouse
eventMouseMove // only used when no button is down, otherwise it's eventMouse
eventFocus
eventPaste
eventInterrupt
eventError
eventRaw
@ -417,6 +421,11 @@ func (g *Gui) pollEvent() GocuiEvent {
Type: eventFocus,
Focused: tev.Focused,
}
case *tcell.EventPaste:
return GocuiEvent{
Type: eventPaste,
Start: tev.Start(),
}
default:
return GocuiEvent{Type: eventNone}
}