Files
OpenSpace/data/assets/util/testing_keybindings.asset
2021-12-28 23:40:09 +01:00

23 lines
644 B
Lua

--testing_keybindings.asset
local propertyHelper = asset.require("./property_helper")
local take_screenshot = {
Identifier = "testing_keyboard.take_screenshot",
Name = "Take Screenshot",
Command = "openspace.takeScreenshot()",
Documentation = "Saves the contents of the screen to a file in the ${SCREENSHOTS} directory.",
GuiPath = "/Rendering",
IsLocal = true
}
asset.onInitialize(function()
openspace.action.registerAction(take_screenshot)
openspace.bindKey("F7", take_screenshot.Identifier)
end)
asset.onDeinitialize(function ()
openspace.action.removeAction(take_screenshot.Identifier)
openspace.clearKey("F7")
end)