From: Teemu Hukkanen Date: Fri, 8 Feb 2013 20:12:16 +0000 (+0100) Subject: Scale fullscreen mode based on current screen X-Git-Tag: 2.1.1~44 X-Git-Url: http://shamusworld.gotdns.org/cgi-bin/gitweb.cgi?p=virtualjaguar;a=commitdiff_plain;h=da13c0c4d801c2838b18fe6492cbe4a7b576164b Scale fullscreen mode based on current screen --- diff --git a/src/gui/mainwin.cpp b/src/gui/mainwin.cpp index 1dbafa0..85a94da 100644 --- a/src/gui/mainwin.cpp +++ b/src/gui/mainwin.cpp @@ -876,7 +876,8 @@ void MainWin::SetFullScreen(bool state/*= true*/) menuBar()->hide(); statusBar()->hide(); showFullScreen(); - QRect r = QApplication::desktop()->availableGeometry(); + int screenNum = QApplication::desktop()->screenNumber(videoWidget); + QRect r = QApplication::desktop()->availableGeometry(screenNum); // double targetWidth = 320.0, targetHeight = (vjs.hardwareTypeNTSC ? 240.0 : 256.0); double targetWidth = (double)VIRTUAL_SCREEN_WIDTH, targetHeight = (double)(vjs.hardwareTypeNTSC ? VIRTUAL_SCREEN_HEIGHT_NTSC : VIRTUAL_SCREEN_HEIGHT_PAL);