mirror of
https://github.com/dolphin-emu/dolphin
synced 2024-07-03 08:48:48 +00:00
MemoryViewWidget:: Add auto update toggle.
This commit is contained in:
parent
3a8fae3960
commit
cb35b93a86
|
@ -255,6 +255,12 @@ void MemoryWidget::CreateWidgets()
|
|||
&MemoryWidget::OnSetValueFromFile);
|
||||
menubar->addMenu(menu_import);
|
||||
|
||||
auto* auto_update_action =
|
||||
menu_views->addAction(tr("Auto update memory values"), this,
|
||||
[this](bool checked) { m_auto_update_enabled = checked; });
|
||||
auto_update_action->setCheckable(true);
|
||||
auto_update_action->setChecked(true);
|
||||
|
||||
auto* highlight_update_action =
|
||||
menu_views->addAction(tr("Highlight recently changed values"), this,
|
||||
[this](bool checked) { m_memory_view->ToggleHighlights(checked); });
|
||||
|
@ -376,7 +382,7 @@ void MemoryWidget::RemoveAfterFrameEventCallback()
|
|||
|
||||
void MemoryWidget::AutoUpdateTable()
|
||||
{
|
||||
if (!isVisible())
|
||||
if (!isVisible() || !m_auto_update_enabled)
|
||||
return;
|
||||
|
||||
m_memory_view->UpdateOnFrameEnd();
|
||||
|
|
|
@ -116,4 +116,6 @@ private:
|
|||
QRadioButton* m_bp_write_only;
|
||||
QCheckBox* m_bp_log_check;
|
||||
Common::EventHook m_VI_end_field_event;
|
||||
|
||||
bool m_auto_update_enabled = true;
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue
Block a user