diff options
Diffstat (limited to 'qtmips_gui/mainwindow.h')
-rw-r--r-- | qtmips_gui/mainwindow.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/qtmips_gui/mainwindow.h b/qtmips_gui/mainwindow.h index 13c8295..976c21e 100644 --- a/qtmips_gui/mainwindow.h +++ b/qtmips_gui/mainwindow.h @@ -58,10 +58,12 @@ #include "qtmipsmachine.h" #include "machineconfig.h" #include "srceditor.h" +#include "simpleasm.h" class MainWindow : public QMainWindow { Q_OBJECT + friend class SimpleAsmWithEditorCheck; public: explicit MainWindow(QWidget *parent = nullptr); ~MainWindow(); @@ -165,4 +167,16 @@ private: bool ignore_unsaved; }; +class SimpleAsmWithEditorCheck : public SimpleAsm { + Q_OBJECT + using Super = SimpleAsm; + +public: + SimpleAsmWithEditorCheck(MainWindow *a_mainwindow, QObject *parent = nullptr) : + Super(parent), mainwindow(a_mainwindow) {} + bool process_file(QString filename, QString *error_ptr = nullptr) override; +private: + MainWindow *mainwindow; +}; + #endif // MAINWINDOW_H |