Rebase: Make archive detection more robust and add it to the CLI (#1560)

* Rebase/recreate my changes and add MIME support

This commit recreates the changes proposed in #1394 on top of the
current master (b069a2acf1).
This also adds support for determining filetypes using the MIME database
provided by `QMimeDatabase`.

* Move member syntax warning to a more appropriate place

* Deduplicate member syntax warning

* Change warning from "vertical bars" to "|"

* Conform brace placement to coding style

* Fix QFileDialog filter when ArchiveExtensions is empty

* Final cleanup and fixes

- Changes the NDS and GBA ROM MIME-Type constants to QStrings.
- Removes a leftover warning message.
- Uses Type() syntax instead of Type{} syntax for temporaries.

* Explain the origin of the supported archive list

Co-authored-by: Jan Felix Langenbach <insert-penguin@protonmail.com>
This commit is contained in:
Janfel
2023-01-18 00:49:18 +01:00
committed by GitHub
parent d83172e595
commit 3e02d3ff76
4 changed files with 305 additions and 163 deletions

View File

@ -239,6 +239,7 @@ public:
GL::Context* getOGLContext();
bool preloadROMs(QStringList file, QStringList gbafile, bool boot);
QStringList splitArchivePath(const QString& filename, bool useMemberSyntax);
void onAppStateChanged(Qt::ApplicationState state);