summaryrefslogtreecommitdiff
path: root/Source
diff options
context:
space:
mode:
authorPokechu22 <Pokechu022@gmail.com>2022-01-31 10:12:55 -0800
committerPokechu22 <Pokechu022@gmail.com>2022-02-12 11:40:53 -0800
commit99b3ac21e4e51664a67a07c1c6c175a67a352e9d (patch)
tree448ab8b345ad3399db62729f63d5c1281caeca03 /Source
parenta05dd6b7e6b7ffeedc295d5c54c21eeab31c2427 (diff)
NewBreakpointDialog: Fix improperly behaving radio buttons
Diffstat (limited to 'Source')
-rw-r--r--Source/Core/DolphinQt/Debugger/NewBreakpointDialog.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/Source/Core/DolphinQt/Debugger/NewBreakpointDialog.cpp b/Source/Core/DolphinQt/Debugger/NewBreakpointDialog.cpp
index 6a1a3eff7b..3e8bfae69a 100644
--- a/Source/Core/DolphinQt/Debugger/NewBreakpointDialog.cpp
+++ b/Source/Core/DolphinQt/Debugger/NewBreakpointDialog.cpp
@@ -3,6 +3,7 @@
#include "DolphinQt/Debugger/NewBreakpointDialog.h"
+#include <QButtonGroup>
#include <QCheckBox>
#include <QDialogButtonBox>
#include <QGridLayout>
@@ -31,10 +32,12 @@ NewBreakpointDialog::NewBreakpointDialog(BreakpointWidget* parent)
void NewBreakpointDialog::CreateWidgets()
{
m_buttons = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel);
+ auto* type_group = new QButtonGroup(this);
// Instruction BP
m_instruction_bp = new QRadioButton(tr("Instruction Breakpoint"));
m_instruction_bp->setChecked(true);
+ type_group->addButton(m_instruction_bp);
m_instruction_box = new QGroupBox;
m_instruction_address = new QLineEdit;
@@ -45,11 +48,15 @@ void NewBreakpointDialog::CreateWidgets()
// Memory BP
m_memory_bp = new QRadioButton(tr("Memory Breakpoint"));
+ type_group->addButton(m_memory_bp);
m_memory_box = new QGroupBox;
+ auto* memory_type_group = new QButtonGroup(this);
m_memory_use_address = new QRadioButton(tr("Address"));
m_memory_use_address->setChecked(true);
+ memory_type_group->addButton(m_memory_use_address);
// i18n: A range of memory addresses
m_memory_use_range = new QRadioButton(tr("Range"));
+ memory_type_group->addButton(m_memory_use_range);
m_memory_address_from = new QLineEdit;
m_memory_address_to = new QLineEdit;
m_memory_address_from_label = new QLabel; // Set by OnAddressTypeChanged