mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 06:09:50 -06:00
Add Break On Hit and Log On Hit for instruction breakpoints
This commit is contained in:
@ -62,12 +62,12 @@ void NewBreakpointDialog::CreateWidgets()
|
||||
m_memory_on_read_and_write = new QRadioButton(tr("Read or Write"));
|
||||
m_memory_on_write->setChecked(true);
|
||||
// i18n: This is a selectable action when adding a breakpoint
|
||||
m_memory_do_log = new QRadioButton(tr("Write to Log"));
|
||||
m_do_log = new QRadioButton(tr("Write to Log"));
|
||||
// i18n: This is a selectable action when adding a breakpoint
|
||||
m_memory_do_break = new QRadioButton(tr("Break"));
|
||||
m_do_break = new QRadioButton(tr("Break"));
|
||||
// i18n: This is a selectable action when adding a breakpoint
|
||||
m_memory_do_log_and_break = new QRadioButton(tr("Write to Log and Break"));
|
||||
m_memory_do_log_and_break->setChecked(true);
|
||||
m_do_log_and_break = new QRadioButton(tr("Write to Log and Break"));
|
||||
m_do_log_and_break->setChecked(true);
|
||||
|
||||
auto* memory_layout = new QGridLayout;
|
||||
m_memory_box->setLayout(memory_layout);
|
||||
@ -89,10 +89,9 @@ void NewBreakpointDialog::CreateWidgets()
|
||||
QGroupBox* action_box = new QGroupBox(tr("Action"));
|
||||
auto* action_layout = new QHBoxLayout;
|
||||
action_box->setLayout(action_layout);
|
||||
memory_layout->addWidget(action_box, 3, 0, 1, -1);
|
||||
action_layout->addWidget(m_memory_do_log);
|
||||
action_layout->addWidget(m_memory_do_break);
|
||||
action_layout->addWidget(m_memory_do_log_and_break);
|
||||
action_layout->addWidget(m_do_log);
|
||||
action_layout->addWidget(m_do_break);
|
||||
action_layout->addWidget(m_do_log_and_break);
|
||||
|
||||
auto* layout = new QVBoxLayout;
|
||||
|
||||
@ -100,6 +99,7 @@ void NewBreakpointDialog::CreateWidgets()
|
||||
layout->addWidget(m_instruction_box);
|
||||
layout->addWidget(m_memory_bp);
|
||||
layout->addWidget(m_memory_box);
|
||||
layout->addWidget(action_box);
|
||||
layout->addWidget(m_buttons);
|
||||
|
||||
setLayout(layout);
|
||||
@ -150,8 +150,8 @@ void NewBreakpointDialog::accept()
|
||||
bool on_write = m_memory_on_write->isChecked() || m_memory_on_read_and_write->isChecked();
|
||||
|
||||
// Actions
|
||||
bool do_log = m_memory_do_log->isChecked() || m_memory_do_log_and_break->isChecked();
|
||||
bool do_break = m_memory_do_break->isChecked() || m_memory_do_log_and_break->isChecked();
|
||||
bool do_log = m_do_log->isChecked() || m_do_log_and_break->isChecked();
|
||||
bool do_break = m_do_break->isChecked() || m_do_log_and_break->isChecked();
|
||||
|
||||
bool good;
|
||||
|
||||
@ -165,7 +165,7 @@ void NewBreakpointDialog::accept()
|
||||
return;
|
||||
}
|
||||
|
||||
m_parent->AddBP(address);
|
||||
m_parent->AddBP(address, false, do_break, do_log);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Reference in New Issue
Block a user