https://bitbucket.org/daniel_fort/magic-lantern
Raw File
Tip revision: 5b786d9f1da39704c4d1ee4a9b4ea27774fec4f6 authored by a1ex on 19 June 2016, 18:13:09 UTC
Close branch find_available_rst2html_command_2nd_try.
Tip revision: 5b786d9
scrnshot.lua
-- take a screenshot every time a key is pressed

scrnshot_menu = menu.new
{
    name = "Screenshot on Keypress",
    choices = { "Off", "On" },
    value = "Off",
}

function event.keypress(key)
    if key ~= 0 and scrnshot_menu.value == "On" then
        display.screenshot()
    end
end
back to top