Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void Widget::on_buttonImport_clicked() {
- string filename = QFileDialog::getOpenFileName().toStdString();
- ifstream f;
- f.open(filename.c_str());
- string s;
- getline(f, s);
- for (int i = 0; i < ui->comboGestures->count(); i++) {
- getline(f, s);
- QStringList nums = QString::fromStdString(s).split(";", QString::SkipEmptyParts);
- for (int j = 1; j < nums.count() - 1; j++) {
- count[i][j] = nums[j].toInt();
- }
- failRate[i] = nums[nums.count() - 1].replace(",", ".").toDouble();
- }
- f.close();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement