hundredrabbits / Pilot

Orca's best friend.
http://wiki.xxiivv.com/Pilot
MIT License
523 stars 41 forks source link

Stop recording with esc key #29

Closed mactkg closed 5 years ago

mactkg commented 5 years ago

Implemented #15.

neauoire commented 5 years ago

Perfect thanks :)

mactkg commented 5 years ago

@neauoire Oh thank you for your fast response! 🏎

but I want to find a more suitable place of this code. https://github.com/mactkg/Pilot/blob/ba0a8193cff1b8f3ae8aabc97cc2ed53c4ce2c35/desktop/sources/index.html#L54-L61

My first idea is write the code into commander.js because orca's code handle onkeydown or onkeyup in commander.js. However, Pilot's comander.js has different role a bit, and it's weird to write there. If you have any good idea, please refactor the code 🙏

neauoire commented 5 years ago

You could also replace with:

controller.add("default","File","Stop Recording",() => { pilot.recorder.stop() },"Escape")
neauoire commented 5 years ago

Fixed :)