By the by, StretchBackgrounds is hardcoded

By the by, StretchBackgrounds is hardcoded or used by whatever calls
this.  Also, only you can prevent pillarboxing.
This commit is contained in:
Colby Klein
2013-10-20 10:10:29 -07:00
parent 88c0bbf8c9
commit 5feef28f4d
+1 -6
View File
@@ -152,12 +152,7 @@ function Actor:FullScreen()
end
function Actor:scale_or_crop_background()
if PREFSMAN:GetPreference("StretchBackgrounds") then
self:cropto(SCREEN_WIDTH, SCREEN_HEIGHT)
else
local graphicAspect = self:GetWidth()/self:GetHeight()
self:zoomto(SCREEN_HEIGHT*graphicAspect,SCREEN_HEIGHT)
end
self:scaletocover(0, 0, SCREEN_WIDTH, SCREEN_HEIGHT)
end
function Actor:CenterX() self:x(SCREEN_CENTER_X) end