Removed on_ from the name of the slots to prevent warning about not being able to find the signals.

The old name followed the pattern used by Qt to automatically deduce what signal should
be connected to which slot. However as these are signals from a sub object it cannot find
them and I have made the connections manually. To prevent getting warnings at runtime
I changed the name.
This commit is contained in:
eelke 2018-01-06 21:33:24 +01:00
parent 97d4e2a1a4
commit ec78dafa94
2 changed files with 9 additions and 9 deletions

View file

@ -51,13 +51,13 @@ TablesPage::TablesPage(QWidget *parent) :
connect(ui->tableListTable->selectionModel(), &QItemSelectionModel::currentRowChanged, this,
&TablesPage::on_tableListTable_currentRowChanged);
&TablesPage::tableListTable_currentRowChanged);
// connect(ui->constraintsTable->selectionModel(), &QItemSelectionModel::currentRowChanged, this,
// &TablesPage::on_constraintsTable_currentRowChanged);
// &TablesPage::constraintsTable_currentRowChanged);
connect(ui->constraintsTable->selectionModel(), &QItemSelectionModel::selectionChanged, this,
&TablesPage::on_constraintsTable_selectionChanged);
&TablesPage::constraintsTable_selectionChanged);
}
@ -78,7 +78,7 @@ void TablesPage::setCatalog(std::shared_ptr<PgDatabaseCatalog> cat)
}
void TablesPage::on_tableListTable_currentRowChanged(const QModelIndex &current, const QModelIndex &previous)
void TablesPage::tableListTable_currentRowChanged(const QModelIndex &current, const QModelIndex &previous)
{
if (current.row() != previous.row()) {
PgClass table = m_tablesModel->getTable(current.row());
@ -94,7 +94,7 @@ void TablesPage::on_tableListTable_currentRowChanged(const QModelIndex &current,
}
}
void TablesPage::on_constraintsTable_currentRowChanged(const QModelIndex &current, const QModelIndex &previous)
void TablesPage::constraintsTable_currentRowChanged(const QModelIndex &current, const QModelIndex &previous)
{
if (current.row() != previous.row()) {
// QString drop_definition = m_constraintModel->dropDefinition(current.row());
@ -107,7 +107,7 @@ void TablesPage::on_constraintsTable_currentRowChanged(const QModelIndex &curren
}
}
void TablesPage::on_constraintsTable_selectionChanged(const QItemSelection &selected, const QItemSelection &deselected)
void TablesPage::constraintsTable_selectionChanged(const QItemSelection &selected, const QItemSelection &deselected)
{
const auto indexes = ui->constraintsTable->selectionModel()->selectedIndexes();
boost::container::flat_set<int> rijen;