all repos — mgba @ 0798d340220df61556c29ed8ee494b96766ebe8c

mGBA Game Boy Advance Emulator

Qt: Fix open ROM dialog filtering for archive formats
Jeffrey Pfau jeffrey@endrift.com
Tue, 19 May 2015 00:18:07 -0700
commit

0798d340220df61556c29ed8ee494b96766ebe8c

parent

6c07ec0fc1ae773f4d7a93f1246ea64f59f4e0f0

2 files changed, 13 insertions(+), 1 deletions(-)

jump to
M CHANGESCHANGES

@@ -3,6 +3,7 @@ Bugfixes:

- GBA Video: Blended sprites should never have other effects applied - GBA: Fix crash if a 512kb flash save is loaded when a game has a 1Mb flash override - Qt: Better cleanup when a game crashes + - Qt: Fix open ROM dialog filtering for archive formats 0.2.1: (2015-05-13) Bugfixes:
M src/platform/qt/Window.cppsrc/platform/qt/Window.cpp

@@ -200,7 +200,18 @@ bool doPause = m_controller->isLoaded() && !m_controller->isPaused();

if (doPause) { m_controller->setPaused(true); } - QString filename = QFileDialog::getOpenFileName(this, tr("Select ROM"), m_config->getQtOption("lastDirectory").toString(), tr("Game Boy Advance ROMs (*.gba *.zip *.rom *.bin)")); + QStringList formats{ + "*.gba", +#ifdef USE_LIBZIP + "*.zip", +#endif +#ifdef USE_LZMA + "*.7z", +#endif + "*.rom", + "*.bin"}; + QString filter = tr("Game Boy Advance ROMs (%1)").arg(formats.join(QChar(' '))); + QString filename = QFileDialog::getOpenFileName(this, tr("Select ROM"), m_config->getQtOption("lastDirectory").toString(), filter); if (doPause) { m_controller->setPaused(false); }