diff options
| author | Léo Lam <leo@innovatetechnologi.es> | 2018-06-19 22:53:37 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-06-19 22:53:37 +0200 |
| commit | a2bc62dd895cd7504be957cf274c582cc409e1f1 (patch) | |
| tree | 0d993fbe9b4477e47699bf3264ac5074c85c95cf /Source/Core | |
| parent | 18c3e0302f6bca8546516173f4cb3ab0aa896a90 (diff) | |
| parent | 6066ca30b27b5ca25fe5d59f315ecd137d5c52f5 (diff) | |
Merge pull request #7140 from lioncash/move
DolphinQt2/RegisterWidget: std::move std::function instances in AddRegister()
Diffstat (limited to 'Source/Core')
| -rw-r--r-- | Source/Core/DolphinQt2/Debugger/RegisterWidget.cpp | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/Source/Core/DolphinQt2/Debugger/RegisterWidget.cpp b/Source/Core/DolphinQt2/Debugger/RegisterWidget.cpp index 2a2fff7aa2..2c063c4821 100644 --- a/Source/Core/DolphinQt2/Debugger/RegisterWidget.cpp +++ b/Source/Core/DolphinQt2/Debugger/RegisterWidget.cpp @@ -4,6 +4,13 @@ #include "DolphinQt2/Debugger/RegisterWidget.h" +#include <utility> + +#include <QHeaderView> +#include <QMenu> +#include <QTableWidget> +#include <QVBoxLayout> + #include "Core/Core.h" #include "Core/HW/ProcessorInterface.h" #include "Core/PowerPC/PowerPC.h" @@ -11,11 +18,6 @@ #include "DolphinQt2/QtUtils/ActionHelper.h" #include "DolphinQt2/Settings.h" -#include <QHeaderView> -#include <QMenu> -#include <QTableWidget> -#include <QVBoxLayout> - RegisterWidget::RegisterWidget(QWidget* parent) : QDockWidget(parent) { setWindowTitle(tr("Registers")); @@ -335,7 +337,7 @@ void RegisterWidget::PopulateTable() void RegisterWidget::AddRegister(int row, int column, RegisterType type, std::string register_name, std::function<u64()> get_reg, std::function<void(u64)> set_reg) { - auto* value = new RegisterColumn(type, get_reg, set_reg); + auto* value = new RegisterColumn(type, std::move(get_reg), std::move(set_reg)); if (m_table->rowCount() <= row) m_table->setRowCount(row + 1); |
