Trying to connect a pair of mutually exclusive radio buttons to slots in a different class.
Signals originate from class EnterLog when a radio button is clicked and should be received in ControlDB. The slot functions are defined as public slots in ControlDB.
Here is the code in ControlDB:

Qt Code:
  1. public slots:
  2. void setSingleModeEdit();
  3. void setSingleModeEntry();
To copy to clipboard, switch view to plain text mode 

Qt Code:
  1. void ControlDB::setSingleModeEdit() {
  2. qDebug() << "single display mode changed to EDIT";
  3. QSqlDatabase db = QSqlDatabase::database(ctrlConn);
  4. QSqlQuery query(db);
  5. query.prepare("UPDATE preferences set defaultSingleView = ?");
  6. query.addBindValue("EDIT");
  7. query.exec();
  8. }
  9.  
  10. void ControlDB::setSingleModeEntry() {
  11. qDebug() << "single display mode changed to ENTRY";
  12. QSqlDatabase db = QSqlDatabase::database(ctrlConn);
  13. QSqlQuery query(db);
  14. query.prepare("UPDATE preferences set defaultSingleView = ?");
  15. query.addBindValue("ENTRY");
  16. query.exec();
  17. }
To copy to clipboard, switch view to plain text mode 

Here is the code in EnterLog:

Qt Code:
  1. ControlDB ctrl;
  2. connect(ui->rbEdit, SIGNAL(clicked()), &ctrl, SLOT(setSingleModeEdit()));
  3. connect(ui->rbEntry, SIGNAL(clicked()), &ctrl, SLOT(setSingleModeEntry()));
To copy to clipboard, switch view to plain text mode 

The problem is, the signals don't get received. What am I doing wrong here?