Skip to content

Commit

Permalink
Qt: Allow for larger screen sizes.
Browse files Browse the repository at this point in the history
  • Loading branch information
unknownbrackets committed Jun 9, 2018
1 parent a448ef5 commit b3c2151
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 7 deletions.
8 changes: 4 additions & 4 deletions Qt/mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -382,8 +382,8 @@ void MainWindow::SetWindowScale(int zoom) {
// Update to the specified factor. Let's clamp first.
if (zoom < 1)
zoom = 1;
if (zoom > 4)
zoom = 4;
if (zoom > 10)
zoom = 10;

width = (g_Config.IsPortrait() ? 272 : 480) * zoom;
height = (g_Config.IsPortrait() ? 480 : 272) * zoom;
Expand Down Expand Up @@ -496,8 +496,8 @@ void MainWindow::createMenus()
// - Screen Size
MenuTree* screenMenu = new MenuTree(this, videoMenu, QT_TR_NOOP("&Screen Size"));
screenGroup = new MenuActionGroup(this, screenMenu, SLOT(screenGroup_triggered(QAction *)),
QStringList() << "1x" << "2x" << "3x" << "4x",
QList<int>() << 1 << 2 << 3 << 4,
QStringList() << "1x" << "2x" << "3x" << "4x" << "5x" << "6x" << "7x" << "8x" << "9x" << "10x",
QList<int>() << 1 << 2 << 3 << 4 << 5 << 6 << 7 << 8 << 9 << 10,
QList<int>() << Qt::CTRL + Qt::Key_1 << Qt::CTRL + Qt::Key_2 << Qt::CTRL + Qt::Key_3 << Qt::CTRL + Qt::Key_4);

MenuTree* displayLayoutMenu = new MenuTree(this, videoMenu, QT_TR_NOOP("&Display Layout Options"));
Expand Down
15 changes: 12 additions & 3 deletions Qt/mainwindow.h
Original file line number Diff line number Diff line change
Expand Up @@ -99,12 +99,18 @@ private slots:
// Video
void anisotropicGroup_triggered(QAction *action) { g_Config.iAnisotropyLevel = action->data().toInt(); }

void bufferRenderAct() { g_Config.iRenderingMode = !g_Config.iRenderingMode; }
void bufferRenderAct() {
g_Config.iRenderingMode = !g_Config.iRenderingMode;
NativeMessageReceived("gpu_resized", "");
}
void linearAct() { g_Config.iTexFiltering = (g_Config.iTexFiltering != 0) ? 0 : 3; }

void screenGroup_triggered(QAction *action) { SetWindowScale(action->data().toInt()); }

void displayLayoutGroup_triggered(QAction *action) { g_Config.iSmallDisplayZoomType = action->data().toInt(); }
void displayLayoutGroup_triggered(QAction *action) {
g_Config.iSmallDisplayZoomType = action->data().toInt();
NativeMessageReceived("gpu_resized", "");
}
void transformAct() { g_Config.bHardwareTransform = !g_Config.bHardwareTransform; }
void vertexCacheAct() { g_Config.bVertexCache = !g_Config.bVertexCache; }
void frameskipAct() { g_Config.iFrameSkip = !g_Config.iFrameSkip; }
Expand All @@ -114,7 +120,10 @@ private slots:

void fullscrAct();
void raiseTopMost();
void statsAct() { g_Config.bShowDebugStats = !g_Config.bShowDebugStats; }
void statsAct() {
g_Config.bShowDebugStats = !g_Config.bShowDebugStats;
NativeMessageReceived("clear jit", "");
}
void showFPSAct() { g_Config.iShowFPSCounter = !g_Config.iShowFPSCounter; }

// Logs
Expand Down

0 comments on commit b3c2151

Please sign in to comment.