summaryrefslogtreecommitdiff
path: root/Source/Core/DolphinQt/Debugger/BranchWatchDialog.cpp
diff options
context:
space:
mode:
authormitaclaw <140017135+mitaclaw@users.noreply.github.com>2024-04-30 10:58:16 -0700
committermitaclaw <140017135+mitaclaw@users.noreply.github.com>2024-04-30 11:17:28 -0700
commit0397339ab1fbdf6309ab14dbf48946853c608522 (patch)
tree0f116933da42d99f743817f75110b037082619b4 /Source/Core/DolphinQt/Debugger/BranchWatchDialog.cpp
parente69486d2cb4e3e01dd622d760350b26d6cbd59f5 (diff)
DolphinQt: Properly Delete (Some) Widgets
This is not every memory leak, just the ones that were obvious.
Diffstat (limited to 'Source/Core/DolphinQt/Debugger/BranchWatchDialog.cpp')
-rw-r--r--Source/Core/DolphinQt/Debugger/BranchWatchDialog.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/Source/Core/DolphinQt/Debugger/BranchWatchDialog.cpp b/Source/Core/DolphinQt/Debugger/BranchWatchDialog.cpp
index a9081c244f..f68b6d5bbf 100644
--- a/Source/Core/DolphinQt/Debugger/BranchWatchDialog.cpp
+++ b/Source/Core/DolphinQt/Debugger/BranchWatchDialog.cpp
@@ -806,6 +806,8 @@ void BranchWatchDialog::OnTableContextMenu(const QPoint& pos)
QModelIndexList index_list = m_table_view->selectionModel()->selectedRows(index.column());
QMenu* const menu = new QMenu;
+ menu->setAttribute(Qt::WA_DeleteOnClose, true);
+
menu->addAction(tr("&Delete"), [this, index_list]() { OnTableDelete(std::move(index_list)); });
switch (index.column())
{