| 108 | } |
| 109 | |
| 110 | void |
| 111 | DeviceTweaks::commitConfig(void) |
| 112 | { |
| 113 | if (this->profile != nullptr) { |
| 114 | auto model = this->ui->tableWidget->model(); |
| 115 | int rows = model->rowCount(); |
| 116 | |
| 117 | this->profile->clearParams(); |
| 118 | |
| 119 | for (int i = 0; i < rows; ++i) { |
| 120 | auto key = this->ui->tableWidget->item(i, 0)->text().toStdString(); |
| 121 | auto val = this->ui->tableWidget->item(i, 1)->text().toStdString(); |
| 122 | |
| 123 | this->profile->setParam(key, val); |
| 124 | } |
| 125 | } |
| 126 | } |
| 127 | |
| 128 | void |
| 129 | DeviceTweaks::setProfile(Suscan::Source::Config *profile) |
no test coverage detected