citra_qt: Migrate to Qt 5 signal/slot connection syntax where applicable

This is more type-safe than the string-based signal/slot syntax that was
being used. It also makes the connections throughout the UI code consistent.
This commit is contained in:
Lioncash
2017-12-17 16:24:19 -05:00
parent 4c3a4ab664
commit a73f135868
13 changed files with 98 additions and 88 deletions

View File

@ -194,20 +194,19 @@ GPUCommandListWidget::GPUCommandListWidget(QWidget* parent)
list_widget->setUniformRowHeights(true);
list_widget->header()->setSectionResizeMode(QHeaderView::ResizeToContents);
connect(list_widget->selectionModel(),
SIGNAL(currentChanged(const QModelIndex&, const QModelIndex&)), this,
SLOT(SetCommandInfo(const QModelIndex&)));
connect(list_widget, SIGNAL(doubleClicked(const QModelIndex&)), this,
SLOT(OnCommandDoubleClicked(const QModelIndex&)));
connect(list_widget->selectionModel(), &QItemSelectionModel::currentChanged, this,
&GPUCommandListWidget::SetCommandInfo);
connect(list_widget, &QTreeView::doubleClicked, this,
&GPUCommandListWidget::OnCommandDoubleClicked);
toggle_tracing = new QPushButton(tr("Start Tracing"));
QPushButton* copy_all = new QPushButton(tr("Copy All"));
connect(toggle_tracing, SIGNAL(clicked()), this, SLOT(OnToggleTracing()));
connect(this, SIGNAL(TracingFinished(const Pica::DebugUtils::PicaTrace&)), model,
SLOT(OnPicaTraceFinished(const Pica::DebugUtils::PicaTrace&)));
connect(toggle_tracing, &QPushButton::clicked, this, &GPUCommandListWidget::OnToggleTracing);
connect(this, &GPUCommandListWidget::TracingFinished, model,
&GPUCommandListModel::OnPicaTraceFinished);
connect(copy_all, SIGNAL(clicked()), this, SLOT(CopyAllToClipboard()));
connect(copy_all, &QPushButton::clicked, this, &GPUCommandListWidget::CopyAllToClipboard);
command_info_widget = nullptr;