mirror of
https://github.com/EnumeratedDev/typer.git
synced 2026-09-16 05:36:10 +00:00
Add key binding and command to run any other command through input bar
This commit is contained in:
+7
-2
@@ -36,6 +36,8 @@ type Window struct {
|
||||
CurrentBuffer *Buffer
|
||||
|
||||
screen tcell.Screen
|
||||
|
||||
closed bool
|
||||
}
|
||||
|
||||
var mouseHeld = false
|
||||
@@ -637,8 +639,11 @@ func (window *Window) handleMouseInput(ev *tcell.EventMouse) {
|
||||
}
|
||||
|
||||
func (window *Window) Close() {
|
||||
window.screen.Fini()
|
||||
window.screen = nil
|
||||
window.closed = true
|
||||
err := window.screen.PostEvent(tcell.NewEventInterrupt(nil))
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
func (window *Window) GetTextAreaDimensions() (int, int, int, int) {
|
||||
|
||||
Reference in New Issue
Block a user