aboutsummaryrefslogtreecommitdiff
path: root/launcher
diff options
context:
space:
mode:
authorRyan Cao <70191398+ryanccn@users.noreply.github.com>2022-10-22 20:51:46 +0800
committerRyan Cao <70191398+ryanccn@users.noreply.github.com>2022-10-22 20:51:46 +0800
commita406aeb3ea8e44f2f511a0755f10d4639f8bfca2 (patch)
tree47e12a908aedbc737be5b57b2804eb1dbb66ba46 /launcher
parent7a8c9637225f457d4648a00ff7d8031acd403730 (diff)
downloadPrismLauncher-a406aeb3ea8e44f2f511a0755f10d4639f8bfca2.tar.gz
PrismLauncher-a406aeb3ea8e44f2f511a0755f10d4639f8bfca2.tar.bz2
PrismLauncher-a406aeb3ea8e44f2f511a0755f10d4639f8bfca2.zip
feat: register as zip/mrpack handler on macOS
Signed-off-by: Ryan Cao <70191398+ryanccn@users.noreply.github.com>
Diffstat (limited to 'launcher')
-rw-r--r--launcher/Application.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/launcher/Application.cpp b/launcher/Application.cpp
index 6ffec1ae..bcb3aa0d 100644
--- a/launcher/Application.cpp
+++ b/launcher/Application.cpp
@@ -943,6 +943,13 @@ bool Application::event(QEvent* event) {
emit clickedOnDock();
}
m_prevAppState = ev->applicationState();
+ return true;
+ }
+
+ if (event->type() == QEvent::FileOpen) {
+ auto ev = static_cast<QFileOpenEvent*>(event);
+ m_mainWindow->droppedURLs({ ev->url() });
+ return true;
}
#endif
return QApplication::event(event);