mirror of https://github.com/KLayout/klayout.git
testing file open event
This commit is contained in:
parent
1e9c7b1246
commit
c82bb445ac
|
|
@ -75,6 +75,11 @@
|
|||
# include <dlfcn.h>
|
||||
#endif
|
||||
|
||||
#if defined(__APPLE__)
|
||||
# include <QFileOpenEvent>
|
||||
# include <QtDebug>
|
||||
#endif
|
||||
|
||||
namespace gsi
|
||||
{
|
||||
void make_application_decl (bool non_gui_mode);
|
||||
|
|
@ -1391,6 +1396,20 @@ GuiApplication::force_update_app_menu ()
|
|||
#endif
|
||||
}
|
||||
|
||||
#if defined(__APPLE__)
|
||||
bool
|
||||
GuiApplication::event(QEvent *event)
|
||||
{
|
||||
if (event->type() == QEvent::FileOpen) {
|
||||
QFileOpenEvent *openEvent = static_cast<QFileOpenEvent *>(event);
|
||||
qDebug() << "Open file" << openEvent->file();
|
||||
}
|
||||
|
||||
return QApplication::event(event);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
int
|
||||
GuiApplication::exec ()
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue