--[[
=head1 NAME

applets.JogglerStandby.JogglerStandbyMeta - JogglerStandby meta-info

=head1 DESCRIPTION

See L<applets.JogglerStandby.JogglerStandbyApplet>.

=head1 FUNCTIONS

See L<jive.AppletMeta> for a description of standard applet meta functions.

=cut
--]]


local os            = require("os")
local oo            = require("loop.simple")
local AppletMeta    = require("jive.AppletMeta")
local appletManager = appletManager
local jiveMain      = jiveMain


module(...)
oo.class(_M, AppletMeta)


function jiveVersion(meta)
	return 1, 1
end


function defaultSettings(meta)
	return {
		standby = 0,
	}
end


function registerApplet(meta)

	jiveMain:addItem(meta:menuItem('appletJogglerStandby', 'screenSettings', "DISPLAYSTANDBY", function(applet, ...) applet:standbySetting(...) end, nil, nil, "player_squeezeplay"))
	os.execute("[ ! -f $HOME/.squeezeplay/userpath/settings/JogglerStandby.lua ] || xset -display :0.0 dpms `cat $HOME/.squeezeplay/userpath/settings/JogglerStandby.lua | awk -F\= {'print $3'} | awk -F\, {'print $1'}` 0 0")
		
end
  


--[[

=head1 LICENSE

Created by Andy Davison
birdslikewires.co.uk

This file is made available under the following Creative Commons licence:

Attribution-ShareAlike 3.0 Unported (CC BY-SA 3.0).

Please see http://creativecommons.org/licenses/by-sa/3.0/ for details.

=cut
--]]
