just some touches to the gui
This commit is contained in:
@@ -31,6 +31,9 @@ void Core::LoadROM(const std::string& rom_) {
|
|||||||
|
|
||||||
cpu->GetMem().LoadROM(isArchive, rom);
|
cpu->GetMem().LoadROM(isArchive, rom);
|
||||||
GameDB::match(cpu->GetMem());
|
GameDB::match(cpu->GetMem());
|
||||||
|
if(cpu->GetMem().rom.gameNameDB.empty()) {
|
||||||
|
cpu->GetMem().rom.gameNameDB = fs::path(rom).stem();
|
||||||
|
}
|
||||||
cpu->GetMem().mmio.vi.isPal = cpu->GetMem().IsROMPAL();
|
cpu->GetMem().mmio.vi.isPal = cpu->GetMem().IsROMPAL();
|
||||||
cpu->GetMem().mmio.si.pif.InitDevices(cpu->GetMem().saveType);
|
cpu->GetMem().mmio.si.pif.InitDevices(cpu->GetMem().saveType);
|
||||||
cpu->GetMem().mmio.si.pif.mempakPath = rom;
|
cpu->GetMem().mmio.si.pif.mempakPath = rom;
|
||||||
|
|||||||
@@ -38,6 +38,9 @@ void KaizenQt::ConnectMainWindowSignalsToSlots() noexcept {
|
|||||||
});
|
});
|
||||||
connect(mainWindow.get(), &MainWindowController::Reset, emuThread.get(), &EmuThread::Reset);
|
connect(mainWindow.get(), &MainWindowController::Reset, emuThread.get(), &EmuThread::Reset);
|
||||||
connect(mainWindow.get(), &MainWindowController::Stop, emuThread.get(), &EmuThread::Stop);
|
connect(mainWindow.get(), &MainWindowController::Stop, emuThread.get(), &EmuThread::Stop);
|
||||||
|
connect(mainWindow.get(), &MainWindowController::Stop, this, [this]() {
|
||||||
|
mainWindow->setWindowTitle("Kaizen");
|
||||||
|
});
|
||||||
connect(mainWindow.get(), &MainWindowController::Pause, emuThread.get(), &EmuThread::TogglePause);
|
connect(mainWindow.get(), &MainWindowController::Pause, emuThread.get(), &EmuThread::TogglePause);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -55,6 +58,7 @@ void KaizenQt::dropEvent(QDropEvent* event) {
|
|||||||
void KaizenQt::LoadROM(const QString& fileName) noexcept {
|
void KaizenQt::LoadROM(const QString& fileName) noexcept {
|
||||||
emuThread->start();
|
emuThread->start();
|
||||||
emuThread->core.LoadROM(fileName.toStdString());
|
emuThread->core.LoadROM(fileName.toStdString());
|
||||||
|
mainWindow->setWindowTitle(emuThread->core.cpu->GetMem().rom.gameNameDB.c_str());
|
||||||
}
|
}
|
||||||
|
|
||||||
void KaizenQt::closeEvent(QCloseEvent*) {
|
void KaizenQt::closeEvent(QCloseEvent*) {
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>800</width>
|
<width>800</width>
|
||||||
<height>600</height>
|
<height>646</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
|
|||||||
Reference in New Issue
Block a user