diff options
| author | 2015-09-02 08:56:38 -0400 | |
|---|---|---|
| committer | 2015-10-04 11:16:59 -0400 | |
| commit | 31dee93e849d79a91f280faf16941806e3cb3c6b (patch) | |
| tree | 22f64217b38dfa38b25a772f9fc5a9b025e1cbd6 /src/citra_qt/main.cpp | |
| parent | OS X build uploading: auto-confirm SSH host key (diff) | |
| download | yuzu-31dee93e849d79a91f280faf16941806e3cb3c6b.tar.gz yuzu-31dee93e849d79a91f280faf16941806e3cb3c6b.tar.xz yuzu-31dee93e849d79a91f280faf16941806e3cb3c6b.zip | |
Implement gdbstub
Diffstat (limited to 'src/citra_qt/main.cpp')
| -rw-r--r-- | src/citra_qt/main.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/citra_qt/main.cpp b/src/citra_qt/main.cpp index 298649aaf..d8d17f466 100644 --- a/src/citra_qt/main.cpp +++ b/src/citra_qt/main.cpp | |||
| @@ -48,6 +48,8 @@ | |||
| 48 | 48 | ||
| 49 | #include "video_core/video_core.h" | 49 | #include "video_core/video_core.h" |
| 50 | 50 | ||
| 51 | #include "core/gdbstub/gdbstub.h" | ||
| 52 | |||
| 51 | GMainWindow::GMainWindow() : emu_thread(nullptr) | 53 | GMainWindow::GMainWindow() : emu_thread(nullptr) |
| 52 | { | 54 | { |
| 53 | Pica::g_debug_context = Pica::DebugContext::Construct(); | 55 | Pica::g_debug_context = Pica::DebugContext::Construct(); |
| @@ -143,6 +145,11 @@ GMainWindow::GMainWindow() : emu_thread(nullptr) | |||
| 143 | 145 | ||
| 144 | game_list->LoadInterfaceLayout(settings); | 146 | game_list->LoadInterfaceLayout(settings); |
| 145 | 147 | ||
| 148 | ui.action_Use_Gdbstub->setChecked(Settings::values.use_gdbstub); | ||
| 149 | SetGdbstubEnabled(ui.action_Use_Gdbstub->isChecked()); | ||
| 150 | |||
| 151 | GDBStub::SetServerPort(static_cast<u32>(Settings::values.gdbstub_port)); | ||
| 152 | |||
| 146 | ui.action_Use_Hardware_Renderer->setChecked(Settings::values.use_hw_renderer); | 153 | ui.action_Use_Hardware_Renderer->setChecked(Settings::values.use_hw_renderer); |
| 147 | SetHardwareRendererEnabled(ui.action_Use_Hardware_Renderer->isChecked()); | 154 | SetHardwareRendererEnabled(ui.action_Use_Hardware_Renderer->isChecked()); |
| 148 | 155 | ||
| @@ -175,6 +182,7 @@ GMainWindow::GMainWindow() : emu_thread(nullptr) | |||
| 175 | connect(ui.action_Stop, SIGNAL(triggered()), this, SLOT(OnStopGame())); | 182 | connect(ui.action_Stop, SIGNAL(triggered()), this, SLOT(OnStopGame())); |
| 176 | connect(ui.action_Use_Hardware_Renderer, SIGNAL(triggered(bool)), this, SLOT(SetHardwareRendererEnabled(bool))); | 183 | connect(ui.action_Use_Hardware_Renderer, SIGNAL(triggered(bool)), this, SLOT(SetHardwareRendererEnabled(bool))); |
| 177 | connect(ui.action_Use_Shader_JIT, SIGNAL(triggered(bool)), this, SLOT(SetShaderJITEnabled(bool))); | 184 | connect(ui.action_Use_Shader_JIT, SIGNAL(triggered(bool)), this, SLOT(SetShaderJITEnabled(bool))); |
| 185 | connect(ui.action_Use_Gdbstub, SIGNAL(triggered(bool)), this, SLOT(SetGdbstubEnabled(bool))); | ||
| 178 | connect(ui.action_Single_Window_Mode, SIGNAL(triggered(bool)), this, SLOT(ToggleWindowMode())); | 186 | connect(ui.action_Single_Window_Mode, SIGNAL(triggered(bool)), this, SLOT(ToggleWindowMode())); |
| 179 | connect(ui.action_Hotkeys, SIGNAL(triggered()), this, SLOT(OnOpenHotkeysDialog())); | 187 | connect(ui.action_Hotkeys, SIGNAL(triggered()), this, SLOT(OnOpenHotkeysDialog())); |
| 180 | 188 | ||
| @@ -445,6 +453,10 @@ void GMainWindow::SetHardwareRendererEnabled(bool enabled) { | |||
| 445 | VideoCore::g_hw_renderer_enabled = enabled; | 453 | VideoCore::g_hw_renderer_enabled = enabled; |
| 446 | } | 454 | } |
| 447 | 455 | ||
| 456 | void GMainWindow::SetGdbstubEnabled(bool enabled) { | ||
| 457 | GDBStub::ToggleServer(enabled); | ||
| 458 | } | ||
| 459 | |||
| 448 | void GMainWindow::SetShaderJITEnabled(bool enabled) { | 460 | void GMainWindow::SetShaderJITEnabled(bool enabled) { |
| 449 | VideoCore::g_shader_jit_enabled = enabled; | 461 | VideoCore::g_shader_jit_enabled = enabled; |
| 450 | } | 462 | } |