--- nono/wx/wxromwindow.cpp 2026/04/29 17:05:12 1.1 +++ nono/wx/wxromwindow.cpp 2026/04/29 17:05:44 1.1.1.3 @@ -15,24 +15,27 @@ // コンストラクタ WXROMWindow::WXROMWindow(wxWindow *parent) - : inherited(parent, wxID_ANY, _("ROM")) + : inherited(parent, wxID_ANY, "ROM") { int row; // ROM はアプリケーション起動後に変化しないので、初回実行時に情報収集。 - if (gMainApp.GetVMType() == VMType::X68030) { + if (gMainApp.IsX68030()) { row = 3; } else { row = 1; } - panel = new WXTextScreen(this, nnSize(52, row)); + auto panel = new WXTextScreen(this, nnSize(52, row)); auto& screen = panel->GetScreen(); - if (gMainApp.GetVMType() == VMType::X68030) { - const char *iplrom1_filename = gIPLROM1->GetFilename(); - const char *iplrom2_filename = gIPLROM2->GetFilename(); - const char *cgrom_filename = gCGROM->GetFilename(); + if (gMainApp.IsX68030()) { + const auto iplrom1 = GetIPLROM1Device(); + const auto iplrom2 = GetIPLROM2Device(); + const auto cgrom = GetCGROMDevice(); + const char *iplrom1_filename = iplrom1->GetFilename(); + const char *iplrom2_filename = iplrom2->GetFilename(); + const char *cgrom_filename = cgrom->GetFilename(); screen.Print(0, 0, "IPLROM1($fe0000-$ffffff,128KB): %s", (iplrom1_filename ? "image file" : "Genuine IPLROM30.DAT")); @@ -41,13 +44,14 @@ WXROMWindow::WXROMWindow(wxWindow *paren screen.Print(0, 2, "CGROM ($f00000-$fbffff,768KB): %s", (cgrom_filename ? "image file" : "nono's builtin")); } else { - const char *prom_filename = gPROM->GetFilename(); + const auto prom = GetPROMDevice(); + const char *prom_filename = prom->GetFilename(); screen.Print(0, 0, "PROM($41000000-): %s", (prom_filename ? "image file" : "nono's builtin")); } - DoSize(); + Fit(); } WXROMWindow::~WXROMWindow()