add overscan to launcher

This commit is contained in:
thrust26 2019-05-16 22:30:37 +02:00
parent ae4a796382
commit e7d2926eba
1 changed files with 3 additions and 2 deletions

View File

@ -32,14 +32,15 @@ Launcher::Launcher(OSystem& osystem)
{
const Common::Size& s = myOSystem.settings().getSize("launcherres");
const Common::Size& d = myOSystem.frameBuffer().desktopSize();
double overscan = 1 - myOSystem.settings().getInt("tia.fs_overscan") / 100.0;
myWidth = s.w; myHeight = s.h;
// The launcher dialog is resizable, within certain bounds
// We check those bounds now
myWidth = std::max(myWidth, FBMinimum::Width);
myHeight = std::max(myHeight, FBMinimum::Height);
myWidth = std::min(myWidth, uInt32(d.w));
myHeight = std::min(myHeight, uInt32(d.h));
myWidth = std::min(myWidth, uInt32(d.w * overscan));
myHeight = std::min(myHeight, uInt32(d.h * overscan));
myOSystem.settings().setValue("launcherres", Common::Size(myWidth, myHeight));