| 490 | } |
| 491 | |
| 492 | void DecoderOptionsDlg::commit_decoder_probes(data::decode::Decoder *dec) |
| 493 | { |
| 494 | assert(dec); |
| 495 | |
| 496 | std::map<const srd_channel*, int> probe_map; |
| 497 | const auto &sigs = AppControl::Instance()->GetSession()->get_signals(); |
| 498 | |
| 499 | std::list<int> index_list; |
| 500 | |
| 501 | for(auto &p : _probe_selectors) |
| 502 | { |
| 503 | if(p._decoder != dec) |
| 504 | break; |
| 505 | |
| 506 | const int selection = p._combo->itemData(p._combo->currentIndex()).value<int>(); |
| 507 | |
| 508 | for(auto s : sigs){ |
| 509 | if(s->get_index() == selection) { |
| 510 | probe_map[p._pdch] = selection; |
| 511 | index_list.push_back(selection); |
| 512 | break; |
| 513 | } |
| 514 | } |
| 515 | } |
| 516 | |
| 517 | dec->set_probes(probe_map); |
| 518 | |
| 519 | if (index_list.size()) |
| 520 | _trace->set_index_list(index_list); |
| 521 | } |
| 522 | |
| 523 | void DecoderOptionsDlg::on_accept() |
| 524 | { |
nothing calls this directly
no test coverage detected