more realism in one more helper
This commit is contained in:
parent
83722db5e4
commit
95be13f9db
6
app.lua
6
app.lua
|
@ -365,9 +365,9 @@ end
|
||||||
|
|
||||||
-- not all keys are textinput
|
-- not all keys are textinput
|
||||||
-- TODO: handle chords of multiple keys
|
-- TODO: handle chords of multiple keys
|
||||||
function App.run_after_keychord(chord)
|
function App.run_after_keychord(chord, key)
|
||||||
App.keychord_press(chord)
|
App.keychord_press(chord, key)
|
||||||
App.keyreleased(chord)
|
App.keyreleased(key)
|
||||||
App.screen.contents = {}
|
App.screen.contents = {}
|
||||||
App.draw()
|
App.draw()
|
||||||
end
|
end
|
||||||
|
|
|
@ -416,8 +416,8 @@ and [the Lua manual](https://www.lua.org/manual/5.1/manual.html).
|
||||||
* `App.run_after_textinput(t)` -- mimics keystrokes resulting in `t` and then
|
* `App.run_after_textinput(t)` -- mimics keystrokes resulting in `t` and then
|
||||||
draws one frame.
|
draws one frame.
|
||||||
|
|
||||||
* `App.run_after_keychord(chord)` -- mimics keystrokes resulting in `chord`
|
* `App.run_after_keychord(chord, key)` -- mimics the final `key` press
|
||||||
and then draws one frame.
|
resulting in `chord` and then draws one frame.
|
||||||
|
|
||||||
* `App.run_after_mouse_press(x,y, mouse_button)` -- mimics a mouse press down
|
* `App.run_after_mouse_press(x,y, mouse_button)` -- mimics a mouse press down
|
||||||
followed by drawing a frame.
|
followed by drawing a frame.
|
||||||
|
|
Loading…
Reference in New Issue