local propertyHelper = asset.require("./property_helper")



-- Function that returns the string that enables/disables the renderable 'renderable'
function toggle(renderable)
  return propertyHelper.invert(renderable .. ".Renderable.Enabled")
end

-- Function that returns the string that sets the enabled property of <renderable> to <enabled>
function setEnabled(renderable, enabled)
  return [[openspace.setPropertyValue("]] .. renderable .. [[.Renderable.Enabled", ]] .. (enabled and "true" or "false") .. ")"
end

asset.export("toggle", toggle)
asset.export("setEnabled", setEnabled)
