// - Remove SDL dependencies (sound, mainly) from Jaguar core lib
// - Fix inconsistency with trailing slashes in paths (eeproms needs one, software doesn't)
//
-// SFDX CODE: 9XF9TUHFM2359
+// SFDX CODE: S1E9T8H5M23YS
// Uncomment this for debugging...
//#define DEBUG
palAct->setChecked(!vjs.hardwareTypeNTSC);
powerAct->setIcon(vjs.hardwareTypeNTSC ? powerRed : powerGreen);
+ fullScreenAct->setChecked(vjs.fullscreen);
fullScreen = vjs.fullscreen;
SetFullScreen(fullScreen);
void MainWin::keyPressEvent(QKeyEvent * e)
{
+ // From jaguar.cpp
+ extern bool startM68KTracing;
+
// We ignore the Alt key for now, since it causes problems with the GUI
if (e->key() == Qt::Key_Alt)
{
e->accept();
return;
}
+ else if (e->key() == Qt::Key_F11)
+ {
+ startM68KTracing = true;
+ e->accept();
+ return;
+ }
+
/*
if (e->key() == Qt::Key_F9)
{
// mainWinSize = size();
menuBar()->hide();
statusBar()->hide();
+ x1Act->setDisabled(true);
+ x2Act->setDisabled(true);
+ x3Act->setDisabled(true);
showFullScreen();
- QRect r = QApplication::desktop()->availableGeometry();
+ // This is needed because the fullscreen may happen on a different
+ // screen than screen 0:
+ 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);
// NOTE: Really should check here to see which dimension constrains the other.
// Right now, we assume that height is the constraint.
int newWidth = (int)(aspectRatio * (double)r.height());
+ videoWidget->offset = (r.width() - newWidth) / 2;
+ videoWidget->fullscreen = true;
+ videoWidget->outputWidth = newWidth;
- videoWidget->setFixedSize(newWidth, r.height());
+// videoWidget->setFixedSize(newWidth, r.height());
+ videoWidget->setFixedSize(r.width(), r.height());
showFullScreen();
}
else
{
+ // Reset the video widget to windowed mode
+ videoWidget->offset = 0;
+ videoWidget->fullscreen = false;
+ x1Act->setDisabled(false);
+ x2Act->setDisabled(false);
+ x3Act->setDisabled(false);
menuBar()->show();
statusBar()->show();
showNormal();