From 19fea0043249e3f7cfdf3f0174590fd7c78f1b86 Mon Sep 17 00:00:00 2001 From: Osvaldo Costa Date: Sun, 17 Nov 2013 23:10:59 -0300 Subject: [PATCH] Change the GUI a little bit Removed the launch of the ELF Compiler window at startup. Instead of it, I added a menubar item called "Compiler", and within it a menu item called "ELF Compiler", wich will launch the window. --- rpcs3/Gui/MainFrame.cpp | 12 ++++++++++++ rpcs3/Gui/MainFrame.h | 1 + rpcs3/rpcs3.cpp | 2 +- 3 files changed, 14 insertions(+), 1 deletion(-) diff --git a/rpcs3/Gui/MainFrame.cpp b/rpcs3/Gui/MainFrame.cpp index 3333064fa4..0510470a67 100644 --- a/rpcs3/Gui/MainFrame.cpp +++ b/rpcs3/Gui/MainFrame.cpp @@ -31,6 +31,7 @@ enum IDs id_config_emu, id_config_vfs_manager, id_config_vhdd_manager, + id_compiler, id_help_about, id_update_dbg, }; @@ -59,11 +60,13 @@ MainFrame::MainFrame() wxMenu& menu_boot(*new wxMenu()); wxMenu& menu_sys(*new wxMenu()); wxMenu& menu_conf(*new wxMenu()); + wxMenu& menu_compiler(*new wxMenu()); wxMenu& menu_help(*new wxMenu()); menubar.Append(&menu_boot, "Boot"); menubar.Append(&menu_sys, "System"); menubar.Append(&menu_conf, "Config"); + menubar.Append(&menu_compiler, "Compiler"); menubar.Append(&menu_help, "Help"); menu_boot.Append(id_boot_game, "Boot game"); @@ -83,6 +86,8 @@ MainFrame::MainFrame() menu_conf.Append(id_config_vfs_manager, "Virtual File System Manager"); menu_conf.Append(id_config_vhdd_manager, "Virtual HDD Manager"); + menu_compiler.Append(id_compiler, "ELF Compiler"); + menu_help.Append(id_help_about, "About..."); SetMenuBar(&menubar); @@ -104,6 +109,8 @@ MainFrame::MainFrame() Connect( id_config_vfs_manager, wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler(MainFrame::ConfigVFS) ); Connect( id_config_vhdd_manager,wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler(MainFrame::ConfigVHDD) ); + Connect( id_compiler, wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler(MainFrame::OpenELFCompiler)); + Connect( id_help_about, wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler(MainFrame::AboutDialogHandler) ); Connect( id_update_dbg, wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler(MainFrame::UpdateUI) ); @@ -478,6 +485,11 @@ void MainFrame::ConfigVHDD(wxCommandEvent& WXUNUSED(event)) VHDDManagerDialog(this).ShowModal(); } +void MainFrame::OpenELFCompiler(wxCommandEvent& WXUNUSED(event)) +{ + (new CompilerELF(this)) -> Show(); +} + void MainFrame::AboutDialogHandler(wxCommandEvent& WXUNUSED(event)) { AboutDialog(this).ShowModal(); diff --git a/rpcs3/Gui/MainFrame.h b/rpcs3/Gui/MainFrame.h index a8d0bc89a6..0199875427 100644 --- a/rpcs3/Gui/MainFrame.h +++ b/rpcs3/Gui/MainFrame.h @@ -30,6 +30,7 @@ private: void Config(wxCommandEvent& event); void ConfigVFS(wxCommandEvent& event); void ConfigVHDD(wxCommandEvent& event); + void OpenELFCompiler(wxCommandEvent& evt); void AboutDialogHandler(wxCommandEvent& event); void UpdateUI(wxCommandEvent& event); void OnKeyDown(wxKeyEvent& event); diff --git a/rpcs3/rpcs3.cpp b/rpcs3/rpcs3.cpp index 31aff4fa1f..a0d857e70f 100644 --- a/rpcs3/rpcs3.cpp +++ b/rpcs3/rpcs3.cpp @@ -22,7 +22,7 @@ bool Rpcs3App::OnInit() SetTopWindow(m_MainFrame); Emu.Init(); - (new CompilerELF(m_MainFrame))->Show(); + // (new CompilerELF(m_MainFrame))->Show(); m_debugger_frame = new DebuggerPanel(m_MainFrame); ConLogFrame = new LogFrame(m_MainFrame);