I forgot :(
This commit is contained in:
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
|
After Width: | Height: | Size: 457 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 114 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 3.8 KiB |
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
|
After Width: | Height: | Size: 621 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 105 KiB |
@@ -0,0 +1,80 @@
|
||||
local function Clock()
|
||||
function UpdateVisible(self)
|
||||
local screen = SCREENMAN:GetTopScreen()
|
||||
local bShow = true
|
||||
if screen then
|
||||
local sClass = screen:GetName()
|
||||
bShow = THEME:GetMetric(sClass, "ShowClock")
|
||||
end
|
||||
if bShow then
|
||||
self:smooth(0.25)
|
||||
self:y(12)
|
||||
else
|
||||
self:smooth(0.25)
|
||||
self:y(-56)
|
||||
end
|
||||
end
|
||||
-- clock
|
||||
clock = Def.ActorFrame {
|
||||
Name="Clock",
|
||||
InitCommand=cmd(x,50;y,12;playcommand,"Update"),
|
||||
ScreenChangedMessageCommand=UpdateVisible,
|
||||
UpdateCommand=cmd(runcommandsonleaves,cmd(queuecommand,"Update")),
|
||||
Def.RoundedBox(90,26)..{ InitCommand=cmd(x,-22;y,-4) },
|
||||
Def.ActorFrame {
|
||||
Name="ClockText",
|
||||
InitCommand=cmd(y,-2),
|
||||
LoadFont("Common", "normal")..{
|
||||
Text="00:00:",
|
||||
InitCommand=cmd(horizalign,right;shadowlength,0;diffusebottomedge,color("0.9,0.9,0.9")),
|
||||
UpdateCommand=function(self)
|
||||
local hour, min = Hour(), Minute()
|
||||
if hour > 12 and GetUserPrefB("Use12HourClock") then
|
||||
hour = hour - 12
|
||||
elseif hour == 0 and GetUserPrefB("Use12HourClock") then
|
||||
hour = 12
|
||||
end
|
||||
self:settext(string.format('%02i:%02i:', hour, min))
|
||||
self:sleep(1)
|
||||
self:queuecommand("Update")
|
||||
end
|
||||
},
|
||||
LoadFont("Common", "normal")..{
|
||||
Text="00",
|
||||
InitCommand=cmd(horizalign,left;shadowlength,0;diffusebottomedge,color("0.9,0.9,0.9")),
|
||||
UpdateCommand=function(self)
|
||||
local sec = Second()
|
||||
self:settext(string.format('%02i', sec))
|
||||
self:sleep(1)
|
||||
self:queuecommand("Update")
|
||||
end,
|
||||
},
|
||||
LoadFont("Common", "normal")..{
|
||||
Text="",
|
||||
InitCommand=cmd(x,28;y,-3;horizalign,left;shadowlength,0;diffusebottomedge,color("0.9,0.9,0.9");visible,false;zoom,0.75),
|
||||
UpdateCommand=function(self)
|
||||
if not GetUserPrefB("Use12HourClock") then
|
||||
self:visible(false)
|
||||
return
|
||||
end
|
||||
local hour = Hour()
|
||||
if hour < 12 then
|
||||
self:settext("AM")
|
||||
self:diffuse(color("1,0.85,0,1"))
|
||||
self:diffusebottomedge(color("0.75,0.55,0,1"))
|
||||
else
|
||||
self:settext("PM")
|
||||
self:diffuse(color("0,0.85,1,1"))
|
||||
self:diffusebottomedge(color("0,0.55,1,1"))
|
||||
end
|
||||
self:visible(true)
|
||||
self:sleep(1)
|
||||
self:queuecommand("Update")
|
||||
end
|
||||
}
|
||||
}
|
||||
}
|
||||
return clock;
|
||||
end
|
||||
local t = Def.ActorFrame {};
|
||||
return t;
|
||||
@@ -0,0 +1,2 @@
|
||||
return LoadFont("Common Normal") .. {
|
||||
};
|
||||
@@ -0,0 +1,2 @@
|
||||
return LoadFont("Common Normal") .. {
|
||||
};
|
||||
@@ -1315,7 +1315,7 @@ SongMeterDisplayOffCommand=
|
||||
#
|
||||
ShowSongTitle=true
|
||||
SongTitleX=SCREEN_CENTER_X
|
||||
SongTitleY=SCREEN_TOP+50+12
|
||||
SongTitleY=SCREEN_TOP+50+6
|
||||
SongTitleOnCommand=draworder,55;shadowlength,1;basezoom,0.5;zoomy,0;sleep,1.5+0.5;smooth,0.5;zoom,1;y,SCREEN_TOP+50+12
|
||||
SongTitleOffCommand=
|
||||
#
|
||||
|
||||
Reference in New Issue
Block a user