[PrefsManager] Add StretchBackgrounds preference.

This commit is contained in:
AJ Kelly
2012-06-02 23:03:47 -05:00
parent a9c8a9517b
commit a564f0c696
10 changed files with 52 additions and 7 deletions
+9 -1
View File
@@ -1,8 +1,16 @@
local Color1 = color(Var "Color1");
local stretchBG = PREFSMAN:GetPreference("StretchBackgrounds")
local t = Def.ActorFrame {
LoadActor(Var "File1") .. {
OnCommand=cmd(x,SCREEN_CENTER_X;y,SCREEN_CENTER_Y;scale_or_crop_background;diffuse,Color1;effectclock,"music");
OnCommand=function(self)
self:xy(SCREEN_CENTER_X,SCREEN_CENTER_Y)
if stretchBG then self:SetSize(SCREEN_WIDTH,SCREEN_HEIGHT)
else self:scale_or_crop_background();
end
self:diffuse(Color1)
self:effectclock("music")
end;
GainFocusCommand=cmd(play);
LoseFocusCommand=cmd(pause);
};