#42 - fix pasting text to EditField
This commit is contained in:
parent
6394ffdb3b
commit
88c829b3f6
7
edit.go
7
edit.go
|
@ -311,8 +311,11 @@ func (e *EditField) ProcessEvent(event Event) bool {
|
||||||
clip.WriteAll(e.Title())
|
clip.WriteAll(e.Title())
|
||||||
return true
|
return true
|
||||||
case term.KeyCtrlV:
|
case term.KeyCtrlV:
|
||||||
s, _ := clip.ReadAll()
|
if !e.readonly {
|
||||||
e.SetTitle(s)
|
s, _ := clip.ReadAll()
|
||||||
|
e.SetTitle(s)
|
||||||
|
e.end()
|
||||||
|
}
|
||||||
return true
|
return true
|
||||||
default:
|
default:
|
||||||
if event.Ch != 0 {
|
if event.Ch != 0 {
|
||||||
|
|
Loading…
Reference in New Issue