summaryrefslogtreecommitdiffstats
path: root/src/citra_qt/main.h
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2015-04-29 06:01:41 +0200
committerbunnei <bunneidev@gmail.com>2015-05-02 00:34:42 +0200
commit43cf42490730d8a1b980aa1fe9ebbbe1249232ef (patch)
treebdaa812eed455d85517130934e4cf17bd56c6d0b /src/citra_qt/main.h
parentQt: Restructured to remove unnecessary shutdown event and various cleanups. (diff)
downloadyuzu-43cf42490730d8a1b980aa1fe9ebbbe1249232ef.tar
yuzu-43cf42490730d8a1b980aa1fe9ebbbe1249232ef.tar.gz
yuzu-43cf42490730d8a1b980aa1fe9ebbbe1249232ef.tar.bz2
yuzu-43cf42490730d8a1b980aa1fe9ebbbe1249232ef.tar.lz
yuzu-43cf42490730d8a1b980aa1fe9ebbbe1249232ef.tar.xz
yuzu-43cf42490730d8a1b980aa1fe9ebbbe1249232ef.tar.zst
yuzu-43cf42490730d8a1b980aa1fe9ebbbe1249232ef.zip
Diffstat (limited to 'src/citra_qt/main.h')
-rw-r--r--src/citra_qt/main.h24
1 files changed, 20 insertions, 4 deletions
diff --git a/src/citra_qt/main.h b/src/citra_qt/main.h
index 1821ae35f..3e29534fb 100644
--- a/src/citra_qt/main.h
+++ b/src/citra_qt/main.h
@@ -5,6 +5,7 @@
#ifndef _CITRA_QT_MAIN_HXX_
#define _CITRA_QT_MAIN_HXX_
+#include <memory>
#include <QMainWindow>
#include "ui_main.h"
@@ -35,9 +36,23 @@ public:
GMainWindow();
~GMainWindow();
- EmuThread* GetEmuThread() {
- return emu_thread;
- }
+signals:
+
+ /**
+ * Signal that is emitted when a new EmuThread has been created and an emulation session is
+ * about to start. At this time, the core system emulation has been initialized, and all
+ * emulation handles and memory should be valid.
+ *
+ * @param emu_thread Pointer to the newly created EmuThread (to be used by widgets that need to
+ * access/change emulation state).
+ */
+ void EmulationStarting(EmuThread* emu_thread);
+
+ /**
+ * Signal that is emitted when emulation is about to stop. At this time, the EmuThread and core
+ * system emulation handles and memory are still valid, but are about become invalid.
+ */
+ void EmulationStopping();
private:
void BootGame(std::string filename);
@@ -60,7 +75,8 @@ private:
Ui::MainWindow ui;
GRenderWindow* render_window;
- EmuThread* emu_thread;
+
+ std::unique_ptr<EmuThread> emu_thread;
ProfilerWidget* profilerWidget;
DisassemblerWidget* disasmWidget;